Salome HOME
Fix regression: storeViewParameters() does not work for OCC view
[modules/geom.git] / src / GEOMAlgo / GEOMAlgo_FinderShapeOn.cxx
index 237e81ef4775d21e29b041eea9ffdf7d8e7120b0..93e475870b8b50275839f8b71023ac3d7a930c46 100644 (file)
@@ -1,28 +1,30 @@
-// Copyright (C) 2005  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-// 
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either 
-// version 2.1 of the License.
-// 
-// This library is distributed in the hope that it will be useful 
-// but WITHOUT ANY WARRANTY; without even the implied warranty of 
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU 
-// Lesser General Public License for more details.
+//  Copyright (C) 2007-2010  CEA/DEN, EDF R&D, OPEN CASCADE
 //
-// You should have received a copy of the GNU Lesser General Public  
-// License along with this library; if not, write to the Free Software 
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
+//  Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+//  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
 //
-// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//  This library is free software; you can redistribute it and/or
+//  modify it under the terms of the GNU Lesser General Public
+//  License as published by the Free Software Foundation; either
+//  version 2.1 of the License.
+//
+//  This library is distributed in the hope that it will be useful,
+//  but WITHOUT ANY WARRANTY; without even the implied warranty of
+//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+//  Lesser General Public License for more details.
+//
+//  You should have received a copy of the GNU Lesser General Public
+//  License along with this library; if not, write to the Free Software
+//  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
+//
+//  See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
 //
-// File:       GEOMAlgo_FinderShapeOn.cxx
-// Created:    Tue Jan 11 14:44:31 2005
-// Author:     Peter KURNEV
-//             <pkv@irinox>
-
 
+// File:        GEOMAlgo_FinderShapeOn.cxx
+// Created:     Tue Jan 11 14:44:31 2005
+// Author:      Peter KURNEV
+//              <pkv@irinox>
+//
 #include <GEOMAlgo_FinderShapeOn.ixx>
 
 #include <gp_Pnt.hxx>
@@ -351,12 +353,12 @@ void GEOMAlgo_FinderShapeOn::Find(const TopoDS_Shape& aS)
     for (; aIt.More(); aIt.Next()) {
       const TopoDS_Shape& aSImage=aIt.Value(); 
       if (myImages.IsBound(aSImage)) { 
-       const TopoDS_Shape& aSx=myImages.Find(aSImage); 
-       myMSS.Add(aSx, aSts[i]);
+        const TopoDS_Shape& aSx=myImages.Find(aSImage); 
+        myMSS.Add(aSx, aSts[i]);
       }
       else {
-       myErrorStatus=33;// can not find original shape
-       return; 
+        myErrorStatus=33;// can not find original shape
+        return; 
       }
     }
   }
@@ -402,21 +404,21 @@ void GEOMAlgo_FinderShapeOn::MakeArgument1()
       switch (aType) {
       case TopAbs_VERTEX: {
         const TopoDS_Vertex& aVx=TopoDS::Vertex(aS);
-       aBB.UpdateVertex(aVx, myTolerance);
+        aBB.UpdateVertex(aVx, myTolerance);
       }
-       break;
+        break;
       case TopAbs_EDGE: {
         const TopoDS_Edge& aEx=TopoDS::Edge(aS);
-       aBB.UpdateEdge(aEx, myTolerance);
+        aBB.UpdateEdge(aEx, myTolerance);
       }
-       break;
+        break;
       case TopAbs_FACE: {
         const TopoDS_Face& aFx=TopoDS::Face(aS);
-       aBB.UpdateFace(aFx, myTolerance);
+        aBB.UpdateFace(aFx, myTolerance);
       }
-       break;
+        break;
       default:
-       break;
+        break;
       }
     }
   } //  
@@ -467,9 +469,9 @@ void GEOMAlgo_FinderShapeOn::CheckData()
   }
   //
   if (!(myShapeType==TopAbs_VERTEX ||
-       myShapeType==TopAbs_EDGE ||
-       myShapeType==TopAbs_FACE ||
-       myShapeType==TopAbs_SOLID)) {
+        myShapeType==TopAbs_EDGE ||
+        myShapeType==TopAbs_FACE ||
+        myShapeType==TopAbs_SOLID)) {
     myErrorStatus=12; // unallowed subshape type
     return;
   }
@@ -486,9 +488,9 @@ void GEOMAlgo_FinderShapeOn::CheckData()
 //purpose  : 
 //=======================================================================
 void GEOMAlgo_FinderShapeOn::CopySource(const TopoDS_Shape& aE,
-                                       TopTools_DataMapOfShapeShape& aImages,
-                                       TopTools_DataMapOfShapeShape& aOriginals,
-                                       TopoDS_Shape& aEx)
+                                        TopTools_DataMapOfShapeShape& aImages,
+                                        TopTools_DataMapOfShapeShape& aOriginals,
+                                        TopoDS_Shape& aEx)
 {
   Standard_Boolean bFree;
   TopAbs_ShapeEnum aType;