]> SALOME platform Git repositories - modules/geom.git/commitdiff
Salome HOME
Temporary patch from VSR: geometry created from script is not checked in
authorvsr <vsr@opencascade.com>
Thu, 6 Dec 2012 09:24:57 +0000 (09:24 +0000)
committervsr <vsr@opencascade.com>
Thu, 6 Dec 2012 09:24:57 +0000 (09:24 +0000)
src/GEOM_SWIG/geompyDC.py

index b072e7c736c38da0dde5951a679288214fd6db0d..8bdcc378bdd91595fb62e2bb53a46e111f5d666a 100644 (file)
@@ -92,8 +92,12 @@ ShapeType = {"AUTO":-1, "COMPOUND":0, "COMPSOLID":1, "SOLID":2, "SHELL":3, "FACE
 ## @ingroup l1_geompy_auxiliary
 def RaiseIfFailed (Method_name, Operation):
     if Operation.IsDone() == 0 and Operation.GetErrorCode() != "NOT_FOUND_ANY":
+        Operation.AbortOperation()
         raise RuntimeError, Method_name + " : " + Operation.GetErrorCode()
-
+    else:
+        Operation.FinishOperation()
+        pass
+        
 ## Return list of variables value from salome notebook
 ## @ingroup l1_geompy_auxiliary
 def ParseParameters(*parameters):
@@ -3012,6 +3016,7 @@ class geompyDC(GEOM._objref_GEOM_Gen):
                 New GEOM.GEOM_Object, containing the created compound.
             """
             # Example: see GEOM_TestAll.py
+            self.ShapesOp.StartOperation()
             anObj = self.ShapesOp.MakeCompound(theShapes)
             RaiseIfFailed("MakeCompound", self.ShapesOp)
             return anObj