From 6aae805714dac28f7aa2498f8060e1f588145645 Mon Sep 17 00:00:00 2001 From: vsv Date: Wed, 3 Jun 2020 20:41:47 +0300 Subject: [PATCH] Issue #3232: Abort current operation if previous automatic constraint caused a conflict --- src/PartSet/PartSet_Module.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/PartSet/PartSet_Module.cpp b/src/PartSet/PartSet_Module.cpp index 623083bae..1e2cb917c 100644 --- a/src/PartSet/PartSet_Module.cpp +++ b/src/PartSet/PartSet_Module.cpp @@ -1872,10 +1872,16 @@ void PartSet_Module::onConflictingConstraints() ModuleBase_Operation* anOpAction = new ModuleBase_Operation(aDescription); XGUI_OperationMgr* anOpMgr = aWorkshop->operationMgr(); + ModuleBase_Operation* anOp = anOpMgr->currentOperation(); + if (sketchMgr()->isNestedSketchOperation(anOp)) + anOp->abort(); + anOpMgr->startOperation(anOpAction); aWorkshop->deleteFeatures(aObjectsList); anOpMgr->commitOperation(); ModuleBase_Tools::flushUpdated(sketchMgr()->activeSketch()); + + myWorkshop->viewer()->update(); } } } -- 2.39.2