From: apo Date: Wed, 12 Oct 2005 11:50:55 +0000 (+0000) Subject: Seocnd fix on Bug GVIEW10215 X-Git-Tag: BR-D5-38-2003_D2005-12-10~3 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=67a20cde571b3404889d10c7d26b8caa98e4e909;p=modules%2Fgui.git Seocnd fix on Bug GVIEW10215 Group creation - incorrect selection --- diff --git a/src/SVTK/SALOME_Actor.cxx b/src/SVTK/SALOME_Actor.cxx index 409b45d9a..51528c5aa 100644 --- a/src/SVTK/SALOME_Actor.cxx +++ b/src/SVTK/SALOME_Actor.cxx @@ -771,8 +771,7 @@ SALOME_Actor bool anIsChanged = (mySelectionMode != theSelectionEvent->mySelectionMode); - mySelectionMode = theSelectionEvent->mySelectionMode; - + Selection_Mode aSelectionMode = theSelectionEvent->mySelectionMode; float x = theSelectionEvent->myX; float y = theSelectionEvent->myY; float z = 0.0; @@ -821,7 +820,7 @@ SALOME_Actor if ( aVtkId >= 0 && theSelector->IsValid( this, aVtkId ) && hasIO() ) { int anObjId = GetElemObjId (aVtkId ); if ( anObjId >= 0 ) { - if ( CheckDimensionId(mySelectionMode,this,anObjId) ) { + if ( CheckDimensionId(aSelectionMode,this,anObjId) ) { TColStd_IndexedMapOfInteger aMapIndex; aMapIndex.Add( anObjId ); @@ -880,6 +879,8 @@ SALOME_Actor } } + mySelectionMode = aSelectionMode; + return anIsChanged; } @@ -939,7 +940,7 @@ SALOME_Actor if( aVtkId >= 0 && theSelector->IsValid( this, aVtkId ) ) { int anObjId = GetElemObjId( aVtkId ); if( anObjId >= 0 ) { - if ( CheckDimensionId(mySelectionMode,this,anObjId) ) { + if ( CheckDimensionId(aSelectionMode,this,anObjId) ) { if( theSelector->IsSelected( myIO ) ) theSelector->AddOrRemoveIndex( myIO, anObjId, isShift ); else { @@ -1059,7 +1060,7 @@ SALOME_Actor int anObjId = GetElemObjId( aCellId ); if( anObjId != -1 ) - if ( CheckDimensionId(mySelectionMode,this,anObjId) ) { + if ( CheckDimensionId(aSelectionMode,this,anObjId) ) { anIndexes.Add(anObjId); } }