if (theCollection) {
for (int i = theCollection->GetNumberOfItems() - 1; i >= 0; i--) {
if (SALOME_Actor* anActor = dynamic_cast<SALOME_Actor*>(theCollection->GetItemAsObject(i)))
- if (anActor->hasIO())
- return anActor;
+ if (anActor->hasIO())
+ return anActor;
}
}
return NULL;
void
SVTK_SelectorDef
::GetIndex( const Handle(SALOME_InteractiveObject)& theIO,
- TColStd_IndexedMapOfInteger& theIndex)
+ TColStd_IndexedMapOfInteger& theIndex)
{
TMapIOSubIndex::const_iterator anIter = myMapIOSubIndex.find(theIO);
if(anIter != myMapIOSubIndex.end())
bool
SVTK_SelectorDef
::IsIndexSelected(const Handle(SALOME_InteractiveObject)& theIO,
- int theIndex) const
+ int theIndex) const
{
TMapIOSubIndex::const_iterator anIter = myMapIOSubIndex.find(theIO);
if(anIter != myMapIOSubIndex.end()){
bool
SVTK_SelectorDef
::AddOrRemoveIndex( const Handle(SALOME_InteractiveObject)& theIO,
- const TColStd_IndexedMapOfInteger& theIndices,
- bool theIsModeShift)
+ const TColStd_IndexedMapOfInteger& theIndices,
+ bool theIsModeShift)
{
TMapIOSubIndex::iterator aMapIter = myMapIOSubIndex.find(theIO);
if(aMapIter == myMapIOSubIndex.end()){
bool
SVTK_SelectorDef
::AddOrRemoveIndex( const Handle(SALOME_InteractiveObject)& theIO,
- const TColStd_MapOfInteger& theIndices,
- bool theIsModeShift)
+ const TColStd_MapOfInteger& theIndices,
+ bool theIsModeShift)
{
TMapIOSubIndex::iterator aMapIter = myMapIOSubIndex.find(theIO);
if(aMapIter == myMapIOSubIndex.end()){
bool
SVTK_SelectorDef
::AddOrRemoveIndex( const Handle(SALOME_InteractiveObject)& theIO,
- int theIndex,
- bool theIsModeShift)
+ int theIndex,
+ bool theIsModeShift)
{
TMapIOSubIndex::iterator anIter = myMapIOSubIndex.find(theIO);
if(anIter == myMapIOSubIndex.end()){
void
SVTK_SelectorDef
::RemoveIndex( const Handle(SALOME_InteractiveObject)& theIO,
- int theIndex)
+ int theIndex)
{
if(IsIndexSelected(theIO,theIndex)){
TMapIOSubIndex::iterator anIter = myMapIOSubIndex.find(theIO);
bool
SVTK_SelectorDef
::IsValid(SALOME_Actor* theActor,
- const TFilterID theId,
- const bool theIsNode) const
+ const TFilterID theId,
+ const bool theIsNode) const
{
TFilters::const_iterator anIter = myFilters.begin();
for(; anIter != myFilters.end(); ++anIter){
vtkActorCollection* aListActors = NULL;
if ( anAdvancedSelectionAlgorithm ) {
myCellPicker->Pick(theEvent->myX,
- theEvent->myY,
- 0.0,
- theRenderer);
+ theEvent->myY,
+ 0.0,
+ theRenderer);
aListActors = myCellPicker->GetActors();
anActor = GetLastSALOMEActor(aListActors);
if ( !anActor ) {
myPicker->Pick(theEvent->myX,
- theEvent->myY,
- 0.0,
- theRenderer);
+ theEvent->myY,
+ 0.0,
+ theRenderer);
aListActors = myPicker->GetActors();
anActor = GetLastSALOMEActor(aListActors);
}
SVTK_SelectorDef
::SetTolerance(const double& theTolerance)
{
- myPicker->SetTolerance(theTolerance);
+ myPicker->SetTolerance(theTolerance);
myCellPicker->SetTolerance(theTolerance);
}