Version: 6.3.1
Public Types | Signals | Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes

LightApp_SelectionMgr Class Reference

#include <LightApp_SelectionMgr.h>

Inheritance diagram for LightApp_SelectionMgr:
Inheritance graph

Public Types

typedef NCollection_DataMap
< Handle(SALOME_InteractiveObject),
TColStd_IndexedMapOfInteger > 
MapIOOfMapOfInteger
typedef NCollection_DataMap
< TCollection_AsciiString,
TColStd_IndexedMapOfInteger > 
MapEntryOfMapOfInteger

Signals

void currentSelectionChanged ()
void selectionChanged ()

Public Member Functions

 LightApp_SelectionMgr (LightApp_Application *, const bool=true)
virtual ~LightApp_SelectionMgr ()
LightApp_Applicationapplication () const
void selectedObjects (SALOME_ListIO &, const QString &=QString(), const bool=true) const
void setSelectedObjects (const SALOME_ListIO &, const bool=false)
void GetIndexes (const Handle(SALOME_InteractiveObject)&IObject, TColStd_IndexedMapOfInteger &theIndex)
void GetIndexes (const QString &theEntry, TColStd_IndexedMapOfInteger &theIndex)
void AddOrRemoveIndex (const Handle(SALOME_InteractiveObject)&IObject, const TColStd_MapOfInteger &theIndices, bool modeShift)
void selectObjects (const Handle(SALOME_InteractiveObject)&IObject, TColStd_IndexedMapOfInteger theIndex, bool append)
void selectObjects (MapIOOfMapOfInteger theMapIO, bool append)
void selectedSubOwners (MapEntryOfMapOfInteger &theMap)
void clearSelected ()
virtual void selected (SUIT_DataOwnerPtrList &, const QString &=QString()) const
virtual void setSelected (const SUIT_DataOwnerPtrList &, const bool=false)
void selectors (QList< SUIT_Selector * > &) const
void selectors (const QString &, QList< SUIT_Selector * > &) const
void setEnabled (const bool, const QString &=QString())
bool hasSelectionMode (const int) const
void selectionModes (QList< int > &) const
void setSelectionModes (const int)
virtual void setSelectionModes (const QList< int > &)
void appendSelectionModes (const int)
virtual void appendSelectionModes (const QList< int > &)
void removeSelectionModes (const int)
virtual void removeSelectionModes (const QList< int > &)
bool isOk (const SUIT_DataOwner *) const
bool isOk (const SUIT_DataOwnerPtr &) const
bool hasFilter (SUIT_SelectionFilter *) const
virtual void installFilter (SUIT_SelectionFilter *, const bool=true)
virtual void removeFilter (SUIT_SelectionFilter *)
virtual void clearFilters ()
bool autoDeleteFilter () const
void setAutoDeleteFilter (const bool)
bool isSynchronizing () const

Protected Member Functions

virtual void installSelector (SUIT_Selector *)
virtual void removeSelector (SUIT_Selector *)

Private Member Functions

virtual void selectionChanged (SUIT_Selector *)

Private Attributes

LightApp_ApplicationmyApp

Detailed Description

Custom selection manager, allowing to work with object selection (additionally to data owners) and to access to sub-selection of objects


Member Typedef Documentation

typedef NCollection_DataMap< Handle(SALOME_InteractiveObject), TColStd_IndexedMapOfInteger > LightApp_SelectionMgr.MapIOOfMapOfInteger
typedef NCollection_DataMap< TCollection_AsciiString, TColStd_IndexedMapOfInteger > LightApp_SelectionMgr.MapEntryOfMapOfInteger

Constructor & Destructor Documentation

LightApp_SelectionMgr::LightApp_SelectionMgr ( LightApp_Application app,
const bool  fb = true 
)

Constructor.

LightApp_SelectionMgr::~LightApp_SelectionMgr ( ) [virtual]

Destructor.


Member Function Documentation

LightApp_Application * LightApp_SelectionMgr::application ( ) const

Gets application.

References myApp.

void LightApp_SelectionMgr::selectedObjects ( SALOME_ListIO theList,
const QString &  theType = QString(),
const bool  convertReferences = true 
) const
void LightApp_SelectionMgr::setSelectedObjects ( const SALOME_ListIO lst,
const bool  append = false 
)
void LightApp_SelectionMgr::GetIndexes ( const Handle(SALOME_InteractiveObject)&  IObject,
TColStd_IndexedMapOfInteger &  theIndex 
)
void LightApp_SelectionMgr::GetIndexes ( const QString &  theEntry,
TColStd_IndexedMapOfInteger &  theIndex 
)
void LightApp_SelectionMgr::AddOrRemoveIndex ( const Handle(SALOME_InteractiveObject)&  IObject,
const TColStd_MapOfInteger &  theIndexes,
bool  modeShift 
)
void LightApp_SelectionMgr::selectObjects ( const Handle(SALOME_InteractiveObject)&  IObject,
TColStd_IndexedMapOfInteger  theIndex,
bool  append 
)
void LightApp_SelectionMgr::selectObjects ( MapIOOfMapOfInteger  theMapIO,
bool  append 
)

select 'subobjects' with given indexes

References SUIT_DataOwnerPtrList.append(), and SUIT_SelectionMgr.setSelected().

void LightApp_SelectionMgr::selectedSubOwners ( MapEntryOfMapOfInteger theMap)

get map of selected subowners : object's entry <-> map of indexes

References LightApp_DataOwner.entry(), LightApp_DataSubOwner.index(), SUIT_SelectionMgr.selected(), and TCollection_AsciiString.

void LightApp_SelectionMgr.currentSelectionChanged ( ) [signal]
void LightApp_SelectionMgr::selectionChanged ( SUIT_Selector theSel) [private, virtual]

Emit current selection changed.

Reimplemented from SUIT_SelectionMgr.

References currentSelectionChanged(), and SUIT_SelectionMgr.selectionChanged().

void SUIT_SelectionMgr::clearSelected ( ) [inherited]

Clear selected data owners.

References SUIT_SelectionMgr.setSelected().

void SUIT_SelectionMgr::selected ( SUIT_DataOwnerPtrList lst,
const QString &  type = QString() 
) const [virtual, inherited]

Gets selected data owners from list with type type to list lst.

References SUIT_DataOwnerPtrList.append(), SUIT_DataOwnerPtrList.clear(), and SUIT_SelectionMgr.mySelectors.

void SUIT_SelectionMgr::setSelected ( const SUIT_DataOwnerPtrList lst,
const bool  append = false 
) [virtual, inherited]

Sets selected data owners from lst and append to list, if append - true.

References SUIT_DataOwnerPtrList.append(), SUIT_SelectionMgr.filterOwners(), and SUIT_SelectionMgr.mySelectors.

void SUIT_SelectionMgr::selectors ( QList< SUIT_Selector * > &  lst) const [inherited]

Gets selectors list to lst.

References SUIT_SelectionMgr.mySelectors.

void SUIT_SelectionMgr::selectors ( const QString &  typ,
QList< SUIT_Selector * > &  lst 
) const [inherited]

Gets selectors list to lst with type typ.

References SUIT_SelectionMgr.mySelectors.

void SUIT_SelectionMgr::setEnabled ( const bool  on,
const QString &  typ = QString() 
) [inherited]

Sets ebabled to on for all data owners with type typ.

References SUIT_SelectionMgr.mySelectors.

bool SUIT_SelectionMgr::hasSelectionMode ( const int  mode) const [inherited]

Checks: Is selection manager has selection mode mode?

References SUIT_SelectionMgr.mySelModes.

void SUIT_SelectionMgr::selectionModes ( QList< int > &  vals) const [inherited]

Gets selection modes to list vals.

References SUIT_SelectionMgr.mySelModes.

void SUIT_SelectionMgr::setSelectionModes ( const int  mode) [inherited]

Set selection mode mode to list of selection modes.

void SUIT_SelectionMgr::setSelectionModes ( const QList< int > &  lst) [virtual, inherited]

Sets selection modes list from lst.

References SUIT_SelectionMgr.mySelModes.

void SUIT_SelectionMgr::appendSelectionModes ( const int  mode) [inherited]

Append selection mode mode to list of selection modes.

void SUIT_SelectionMgr::appendSelectionModes ( const QList< int > &  lst) [virtual, inherited]

Append selection modes lst list.

References SUIT_SelectionMgr.mySelModes.

void SUIT_SelectionMgr::removeSelectionModes ( const int  mode) [inherited]

Remove selection mode mode from list.

void SUIT_SelectionMgr::removeSelectionModes ( const QList< int > &  lst) [virtual, inherited]

Remove selection modea lst from list.

References SUIT_SelectionMgr.mySelModes.

bool SUIT_SelectionMgr::isOk ( const SUIT_DataOwner owner) const [inherited]

Checks data owner is ok?

References SUIT_SelectionMgr.myFilters.

bool SUIT_SelectionMgr::isOk ( const SUIT_DataOwnerPtr ptr) const [inherited]

Checks data owner pointer is ok?

References SmartPtr< T >.isNull(), and SUIT_SelectionMgr.isOk().

bool SUIT_SelectionMgr::hasFilter ( SUIT_SelectionFilter f) const [inherited]

Checks selection manager has filter f?

References SUIT_SelectionMgr.myFilters.

void SUIT_SelectionMgr::installFilter ( SUIT_SelectionFilter f,
const bool  updateSelection = true 
) [virtual, inherited]

Install filter f and set selected, if update = true.

References SUIT_SelectionMgr.hasFilter(), SUIT_SelectionMgr.myFilters, SUIT_SelectionMgr.selected(), and SUIT_SelectionMgr.setSelected().

void SUIT_SelectionMgr::removeFilter ( SUIT_SelectionFilter f) [virtual, inherited]

Remove filter f from filters list.

References SUIT_SelectionMgr.autoDeleteFilter(), and SUIT_SelectionMgr.myFilters.

void SUIT_SelectionMgr::clearFilters ( ) [virtual, inherited]
bool SUIT_SelectionMgr::autoDeleteFilter ( ) const [inherited]

Sets auto delete filter.

References SUIT_SelectionMgr.myAutoDelFilter.

void SUIT_SelectionMgr::setAutoDeleteFilter ( const bool  on) [inherited]

Sets auto delete filter to on.

References SUIT_SelectionMgr.myAutoDelFilter.

bool SUIT_SelectionMgr::isSynchronizing ( ) const [inherited]

Returns true if selection manger is in synchronising mode (during synchonisation of the selectors selection).

References SUIT_SelectionMgr.myIsSelChangeEnabled.

void SUIT_SelectionMgr.selectionChanged ( ) [signal, inherited]
void SUIT_SelectionMgr::installSelector ( SUIT_Selector sel) [protected, virtual, inherited]

Add selector sel to selectors list,if it's not exists in list.

References SUIT_SelectionMgr.mySelectors.

void SUIT_SelectionMgr::removeSelector ( SUIT_Selector sel) [protected, virtual, inherited]

Remove selector sel from list.

References SUIT_SelectionMgr.mySelectors.


Field Documentation

Copyright © 2007-2011 CEA/DEN, EDF R&D, OPEN CASCADE
Copyright © 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS