Optika GUI Toolik Version of the Day
Optika::TreeView Class Reference

Class used to view TreeModels. More...

#include <Optika_treeview.hpp>

List of all members.

Public types

typedef std::pair< QModelIndex,
QString > 
invalidIndex
 A pair representing an invalidIndex and why it's invalid.

Constructors

 TreeView (TreeModel *treeModel, Delegate *delegate, QWidget *parent=0)
 Constructs a TreeView.

Public Slots

void showRow (int row, const QModelIndex &parent)
 Used to change the visiblity of a row from hidden to shown.
void hideRow (int row, const QModelIndex &parent)
 Used to change the visiblity of a row from shown to hidden.
void handleBadValue (QModelIndex badValueIndex, QString message)
 Handles any badValue signals that might be emitted by the TreeModel.
void checkForOtherBadValues ()
 Checks to see if there are any other invalid indicies. If there are, it dequeues the next invalidIndex from the invalidIndicies queue and calls the handleBadValue function with it.

Private Members

QQueue< invalidIndexinvalidInicies
 A Queue containing any invalid indicies that need to be delt with.

Detailed Description

Class used to view TreeModels.

Definition at line 59 of file Optika_treeview.hpp.


Member Typedef Documentation

typedef std::pair<QModelIndex, QString> Optika::TreeView::invalidIndex

A pair representing an invalidIndex and why it's invalid.

Definition at line 68 of file Optika_treeview.hpp.


Constructor & Destructor Documentation

Optika::TreeView::TreeView ( TreeModel treeModel,
Delegate delegate,
QWidget *  parent = 0 
)

Constructs a TreeView.

Parameters:
treeModelThe Tree Model being used with the TreeView.
delegateThe delegate to be used with the TreeView.
parentThe parent widget.

Definition at line 46 of file Optika_treeview.cpp.


Member Function Documentation

void Optika::TreeView::showRow ( int  row,
const QModelIndex &  parent 
) [slot]

Used to change the visiblity of a row from hidden to shown.

Parameters:
rowThe row to be shwon.
parentThe parent of the item to be shown.

Definition at line 60 of file Optika_treeview.cpp.

void Optika::TreeView::hideRow ( int  row,
const QModelIndex &  parent 
) [slot]

Used to change the visiblity of a row from shown to hidden.

Parameters:
rowThe row to be shwon.
parentThe parent of the item to be hidden.

Definition at line 66 of file Optika_treeview.cpp.

void Optika::TreeView::handleBadValue ( QModelIndex  badValueIndex,
QString  message 
) [slot]

Handles any badValue signals that might be emitted by the TreeModel.

Parameters:
badValueIndexThe index of the item with the bad value.
Abrief message explaining what happened to cause the treeitem to have an invalid value.

Definition at line 72 of file Optika_treeview.cpp.

void Optika::TreeView::checkForOtherBadValues ( ) [slot]

Checks to see if there are any other invalid indicies. If there are, it dequeues the next invalidIndex from the invalidIndicies queue and calls the handleBadValue function with it.

Definition at line 83 of file Optika_treeview.cpp.


Member Data Documentation

A Queue containing any invalid indicies that need to be delt with.

Definition at line 135 of file Optika_treeview.hpp.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Friends Defines