]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
*** empty log message ***
authorsan <san@opencascade.com>
Fri, 15 Oct 2010 13:03:52 +0000 (13:03 +0000)
committersan <san@opencascade.com>
Fri, 15 Oct 2010 13:03:52 +0000 (13:03 +0000)
src/SUIT/SUIT_SelectionMgr.cxx

index a3f8a8e8116a93736b96e5aae0132a9702d38491..3479c176b1b1c1be9e35a81744d49abb2c28eb54 100755 (executable)
@@ -144,12 +144,20 @@ void SUIT_SelectionMgr::selectionChanged( SUIT_Selector* sel )
   SUIT_DataOwnerPtrList newOwners;
   filterOwners( owners, newOwners );
 
+  QMap<SUIT_DataOwnerPtr, int> map;
+  for ( SUIT_DataOwnerPtrList::iterator itr = owners.begin(); itr != owners.end(); ++itr )
+    map.insert( *itr, 0 );
+
+  for ( SUIT_DataOwnerPtrList::iterator nitr = newOwners.begin(); nitr != newOwners.end(); ++nitr )
+    map.remove( *nitr );
+
+  bool filtered = !map.isEmpty();
+
   for ( int i = 0; i < myIterations; i++ )
   {
     for ( SelectorList::iterator it = mySelectors.begin(); it != mySelectors.end(); ++it )
     {
-      // Temporary action(to avoid selection of the objects which don't pass the filters):
-      //if ( *it != sel )
+      if ( *it != sel || filtered )
        (*it)->setSelected( newOwners );
     }
   }