]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Fix the crashes on new modification history storage, reproducable on Bug2569_shaper9...
authormpv <mpv@opencascade.com>
Mon, 22 Oct 2018 14:39:06 +0000 (17:39 +0300)
committermpv <mpv@opencascade.com>
Mon, 19 Nov 2018 08:45:52 +0000 (11:45 +0300)
src/FeaturesPlugin/FeaturesPlugin_Rotation.cpp
src/GeomAlgoAPI/GeomAlgoAPI_MakeShapeCustom.cpp

index d87346d1aee1e44fc6092ae7df22eb564980d201..f9a11c5c6ac156b1a8c39dbcb62485c48c0836a5 100755 (executable)
@@ -163,6 +163,7 @@ void FeaturesPlugin_Rotation::performTranslationByAxisAndAngle()
       }
 
       ResultBodyPtr aResultBody = document()->createBody(data(), aResultIndex);
+      aResultBody->storeModified(aBaseShape, aRotationAlgo->shape());
       FeaturesPlugin_Tools::loadModifiedShapes(aResultBody, aBaseShape, aRotationAlgo, "Rotated");
       setResult(aResultBody, aResultIndex);
     }
index 81f16868ea9717d559fdcb3ddf3b32a0212a2902..01bf7c8653306f0952625f5725ff0a5e3aca9812 100644 (file)
@@ -22,7 +22,8 @@
 
 //==================================================================================================
 GeomAlgoAPI_MakeShapeCustom::GeomAlgoAPI_MakeShapeCustom()
-{}
+{
+}
 
 //==================================================================================================
 void GeomAlgoAPI_MakeShapeCustom::setResult(const GeomShapePtr theShape)
@@ -36,7 +37,6 @@ bool GeomAlgoAPI_MakeShapeCustom::addModified(const GeomShapePtr theOldShape,
 {
   if (!isValidForHistory(theNewShape)) return false;
   GeomShapePtr aNewShape = theNewShape;
-  fixOrientation(aNewShape);
   return myModified.add(theOldShape, aNewShape);
 }
 
@@ -46,7 +46,6 @@ bool GeomAlgoAPI_MakeShapeCustom::addGenerated(const GeomShapePtr theOldShape,
 {
   if (!isValidForHistory(theNewShape)) return false;
   GeomShapePtr aNewShape = theNewShape;
-  fixOrientation(aNewShape);
   return myGenerated.add(theOldShape, aNewShape);
 }