Salome HOME
refs #430: incorrect coordinates in dump polyline
[modules/hydro.git] / src / HYDROData / HYDROData_Region.cxx
index 8c19d65e635fe91b4d1b4298a7871752b3048d53..ac6a4f757ca6b2ed550d0f98e7b3085005363f74 100644 (file)
@@ -41,25 +41,6 @@ HYDROData_Region::~HYDROData_Region()
 {
 }
 
-QStringList HYDROData_Region::DumpToPython( MapOfTreatedObjects& theTreatedObjects ) const
-{
-  QStringList aResList = HYDROData_Entity::DumpToPython( theTreatedObjects );
-  QString aRegionName = GetName();
-
-  HYDROData_SequenceOfObjects aZones = GetZones();
-  HYDROData_SequenceOfObjects::Iterator anIter( aZones );
-  for ( ; anIter.More(); anIter.Next() )
-  {
-    Handle(HYDROData_Zone) aRefZone =
-      Handle(HYDROData_Zone)::DownCast( anIter.Value() );
-    if ( !aRefZone.IsNull() )
-      setPythonReferenceObject( theTreatedObjects, aResList, aRefZone, "AddZone" );
-  }
-  aResList << QString( "" );
-
-  return aResList;
-}
-
 bool HYDROData_Region::CanBeUpdated() const
 {
   return false;
@@ -185,17 +166,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 );