From: nds Date: Tue, 30 May 2017 14:13:23 +0000 (+0300) Subject: Issue #2176 Incorrect sketch after abort: deactivate of sketch overconstraint listene... X-Git-Tag: V_2.7.1.1~16 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=fb1685b8a7665dd10a3e6b0e0643c9a54afcda07;p=modules%2Fshaper.git Issue #2176 Incorrect sketch after abort: deactivate of sketch overconstraint listener should be done after abort/commit is finished. Solver may send signal about healing conflicts during abort execution. --- diff --git a/src/PartSet/PartSet_Module.cpp b/src/PartSet/PartSet_Module.cpp index 4ba63e7ca..e41ef1667 100755 --- a/src/PartSet/PartSet_Module.cpp +++ b/src/PartSet/PartSet_Module.cpp @@ -255,6 +255,9 @@ void PartSet_Module::operationCommitted(ModuleBase_Operation* theOperation) if (sketchMgr()->isNestedSketchOperation(theOperation)) { mySketchMgr->commitNestedSketch(theOperation); } + /// deactivate of overconstraint listener should be performed after Sketch commit (#2176) + if (PartSet_SketcherMgr::isSketchOperation(theOperation)) + overconstraintListener()->setActive(false); /// Restart sketcher operations automatically if (!mySketchReentrantMgr->operationCommitted(theOperation)) { @@ -274,6 +277,9 @@ void PartSet_Module::operationAborted(ModuleBase_Operation* theOperation) { /// Restart sketcher operations automatically mySketchReentrantMgr->operationAborted(theOperation); + /// deactivate of overconstraint listener should be performed after Sketch abort (#2176) + if (PartSet_SketcherMgr::isSketchOperation(theOperation)) + overconstraintListener()->setActive(false); } void PartSet_Module::operationStarted(ModuleBase_Operation* theOperation) diff --git a/src/PartSet/PartSet_SketcherMgr.cpp b/src/PartSet/PartSet_SketcherMgr.cpp index 9f8e4cf21..33b304bf1 100755 --- a/src/PartSet/PartSet_SketcherMgr.cpp +++ b/src/PartSet/PartSet_SketcherMgr.cpp @@ -1050,7 +1050,6 @@ void PartSet_SketcherMgr::stopSketch(ModuleBase_Operation* theOperation) Events_Loop::loop()->flush(aDispEvent); } - myModule->overconstraintListener()->setActive(false); // restore the module selection modes, which were changed on startSketch aConnector->activateModuleSelectionModes(); }