Object browser selection handler class.
#include <LightApp_OBSelector.h>
Public Member Functions | |
LightApp_OBSelector (SUIT_DataBrowser *, SUIT_SelectionMgr *) | |
Constructor. More... | |
virtual | ~LightApp_OBSelector () |
Destructor. More... | |
SUIT_DataBrowser * | browser () const |
Get object browser. More... | |
virtual QString | type () const |
Get selector type. More... | |
unsigned long | getModifiedTime () const |
Get the time of the last selection changing. More... | |
void | setModified () |
Update the time of the latest selection changing. More... | |
Public Member Functions inherited from SUIT_Selector | |
SUIT_Selector (SUIT_SelectionMgr *, QObject *=0) | |
virtual | ~SUIT_Selector () |
SUIT_SelectionMgr * | selectionMgr () const |
bool | isEnabled () const |
virtual void | setEnabled (const bool) |
bool | autoBlock () const |
virtual void | setAutoBlock (const bool) |
void | selected (SUIT_DataOwnerPtrList &) const |
void | setSelected (const SUIT_DataOwnerPtrList &) |
bool | hasSelectionMode (const int) const |
void | selectionModes (QList< int > &) const |
QObject * | owner () const |
Protected Member Functions | |
virtual void | getSelection (SUIT_DataOwnerPtrList &) const |
Get list of currently selected objects. More... | |
virtual void | setSelection (const SUIT_DataOwnerPtrList &) |
Set selection. More... | |
Protected Member Functions inherited from SUIT_Selector | |
void | selectionChanged () |
Private Slots | |
void | onSelectionChanged () |
Called when the Object browser selection is changed. More... | |
Private Member Functions | |
void | fillEntries (QMap< QString, LightApp_DataObject * > &) |
Fill map of the data objects currently shown in the Object Browser. More... | |
Private Attributes | |
SUIT_DataBrowser * | myBrowser |
SUIT_DataOwnerPtrList | mySelectedList |
QMap< QString, LightApp_DataObject * > | myEntries |
unsigned long | myModifiedTime |
LightApp_OBSelector::LightApp_OBSelector | ( | SUIT_DataBrowser * | ob, |
SUIT_SelectionMgr * | mgr | ||
) |
ob | object browser |
mgr | selection manager |
References myBrowser, onSelectionChanged(), SUIT_Selector::selectionChanged(), and setModified().
|
virtual |
SUIT_DataBrowser * LightApp_OBSelector::browser | ( | ) | const |
References myBrowser.
|
private |
entries | map to be filled |
References SUIT_DataObjectIterator::current(), SUIT_DataObjectIterator::DepthLeft, LightApp_DataObject::entry(), myBrowser, obj, SUIT_DataBrowser::root(), and setModified().
unsigned long LightApp_OBSelector::getModifiedTime | ( | ) | const |
References myModifiedTime.
|
protectedvirtual |
theList | list to be filled with the selected objects owners |
Implements SUIT_Selector.
References SUIT_Session::activeApplication(), app, SUIT_DataOwnerPtrList::append(), LightApp_Application::checkDataObject(), LightApp_DataObject::componentDataType(), LightApp_DataObject::entry(), SUIT_DataBrowser::getSelected(), Handle(), myBrowser, mySelectedList, SUIT_DataObject::name(), obj, SUIT_Selector::owner(), SALOME_InteractiveObject(), and SUIT_Session::session().
|
privateslot |
References SUIT_DataOwnerPtrList::clear(), mySelectedList, and SUIT_Selector::selectionChanged().
void LightApp_OBSelector::setModified | ( | ) |
References myModifiedTime.
|
protectedvirtual |
theList | list of the object owners to be set selected |
Implements SUIT_Selector.
References SUIT_DataOwnerPtrList::clear(), LightApp_DataOwner::entry(), fillEntries(), OB_Browser::getModifiedTime(), myBrowser, myEntries, myModifiedTime, mySelectedList, SUIT_Selector::owner(), and SUIT_DataBrowser::setSelected().
|
virtual |
Implements SUIT_Selector.
|
private |
|
private |
|
private |
|
private |