]> SALOME platform Git repositories - modules/hydro.git/commitdiff
Salome HOME
Workaround replaced by correct piece of code.
authoradv <adv@opencascade.com>
Thu, 16 Jan 2014 08:06:09 +0000 (08:06 +0000)
committeradv <adv@opencascade.com>
Thu, 16 Jan 2014 08:06:09 +0000 (08:06 +0000)
src/HYDROData/HYDROData_Region.cxx

index 406993746966327df83abb31f0c2c5134f9b5179..6548310b060f65b8cff10effb770b90a8f9aede1 100644 (file)
@@ -188,17 +188,8 @@ void getUsedGroups( const TopoDS_Shape&                     theShape,
     {
       TopoDS_Shape aGroupEdge = anOriGroupDef.Shapes.Value( i );
       
-      bool anIsFound = false;
-      for ( int anIndex = 1; anIndex <= aMapOfSubShapes.Extent(); anIndex++ )
-      {
-        if ( aGroupEdge.IsPartner( aMapOfSubShapes.FindKey( anIndex ) ) )
-        {
-          anIsFound = true;
-          break;
-        }
-      }
-
-      if ( !anIsFound )
+      int aShapeIndex = aMapOfSubShapes.FindIndex( aGroupEdge );
+      if ( aShapeIndex <= 0 )
         continue;
 
       anOriGroupDef.Shapes.Remove( i );