![]() |
VR-Forces 4.0.4 Class Documentation
|
Override QTreeWidget to provide additional functionality (mainly right click support) More...

Signals | |
| void | mouseLeftPressed (QTreeWidgetItem *, QMouseEvent *, int col) |
| Emitted when the mouse button is pressed. | |
| void | rightClickOnItem (QTreeWidgetItem *, QMouseEvent *, int col) |
| Emitted when right button is released. | |
| void | contentsMoving (int, int) |
Public Member Functions | |
| DtTreeWidget (QWidget *parent) | |
| Constructor. | |
| virtual QTreeWidgetItem * | lastItem () const |
| Returns the last item in the list. | |
| QTreeWidgetItem * | itemFromIndex (const QModelIndex &idx) |
| QModelIndex | indexFromItem (QTreeWidgetItem *item, int column=0) const |
| virtual int | indexOfChild (QTreeWidgetItem *) const |
| unsigned int | depth (QTreeWidgetItem *) const |
| Returns the number of levels down this item is. | |
| QTreeWidgetItem * | nextSibling (QTreeWidgetItem *) const |
| Returns the next item after the supplied item. | |
| void | setAllowEmptySelection (bool) |
| Only valid in single selection mode. | |
| bool | allowEmptySelection () const |
Protected Member Functions | |
| virtual void | mousePressEvent (QMouseEvent *event) |
| virtual void | mouseReleaseEvent (QMouseEvent *event) |
| virtual void | scrollContentsBy (int, int) |
| virtual QSize | sizeHint () const |
| Need to do this as default sizeHint() for an abstract scroll area (in Qt 4.2.2) is too large. | |
| virtual QItemSelectionModel::SelectionFlags | selectionCommand (const QModelIndex &index, const QEvent *event=0) const |
| Override to allow empty selection in single selection mode. | |
| virtual QItemSelectionModel::SelectionFlags | selectionBehaviorFlags () const |
Protected Attributes | |
| bool | myMouseRightClick |
| bool | myAllowEmptySelection |
Override QTreeWidget to provide additional functionality (mainly right click support)
| DtTreeWidget::DtTreeWidget | ( | QWidget * | parent | ) |
Constructor.
| virtual QTreeWidgetItem* DtTreeWidget::lastItem | ( | ) | const [virtual] |
Returns the last item in the list.
| QTreeWidgetItem* DtTreeWidget::itemFromIndex | ( | const QModelIndex & | idx | ) | [inline] |
| QModelIndex DtTreeWidget::indexFromItem | ( | QTreeWidgetItem * | item, |
| int | column = 0 |
||
| ) | const [inline] |
| virtual int DtTreeWidget::indexOfChild | ( | QTreeWidgetItem * | ) | const [virtual] |
| unsigned int DtTreeWidget::depth | ( | QTreeWidgetItem * | ) | const |
Returns the number of levels down this item is.
| QTreeWidgetItem* DtTreeWidget::nextSibling | ( | QTreeWidgetItem * | ) | const |
Returns the next item after the supplied item.
| void DtTreeWidget::setAllowEmptySelection | ( | bool | b | ) | [inline] |
Only valid in single selection mode.
References myAllowEmptySelection.
| bool DtTreeWidget::allowEmptySelection | ( | ) | const [inline] |
References myAllowEmptySelection.
| void DtTreeWidget::mouseLeftPressed | ( | QTreeWidgetItem * | , |
| QMouseEvent * | , | ||
| int | col | ||
| ) | [signal] |
Emitted when the mouse button is pressed.
If the event is accepted, will not process parent message
| void DtTreeWidget::rightClickOnItem | ( | QTreeWidgetItem * | , |
| QMouseEvent * | , | ||
| int | col | ||
| ) | [signal] |
Emitted when right button is released.
| void DtTreeWidget::contentsMoving | ( | int | , |
| int | |||
| ) | [signal] |
| virtual void DtTreeWidget::mousePressEvent | ( | QMouseEvent * | event | ) | [protected, virtual] |
| virtual void DtTreeWidget::mouseReleaseEvent | ( | QMouseEvent * | event | ) | [protected, virtual] |
| virtual void DtTreeWidget::scrollContentsBy | ( | int | , |
| int | |||
| ) | [protected, virtual] |
| virtual QSize DtTreeWidget::sizeHint | ( | ) | const [protected, virtual] |
Need to do this as default sizeHint() for an abstract scroll area (in Qt 4.2.2) is too large.
| virtual QItemSelectionModel::SelectionFlags DtTreeWidget::selectionCommand | ( | const QModelIndex & | index, |
| const QEvent * | event = 0 |
||
| ) | const [protected, virtual] |
Override to allow empty selection in single selection mode.
| virtual QItemSelectionModel::SelectionFlags DtTreeWidget::selectionBehaviorFlags | ( | ) | const [protected, virtual] |
bool DtTreeWidget::myMouseRightClick [protected] |
bool DtTreeWidget::myAllowEmptySelection [protected] |
Referenced by allowEmptySelection(), and setAllowEmptySelection().