From f71ff8b376995110efd563a967e585a7a5dc8328 Mon Sep 17 00:00:00 2001 From: vsv Date: Fri, 31 Jan 2020 16:52:25 +0300 Subject: [PATCH] Issue #3135: Provide automatic creation of Horizontal and Vertical constraints --- src/PartSet/PartSet_SketcherReentrantMgr.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/PartSet/PartSet_SketcherReentrantMgr.cpp b/src/PartSet/PartSet_SketcherReentrantMgr.cpp index 0e098c8e6..ff241a141 100644 --- a/src/PartSet/PartSet_SketcherReentrantMgr.cpp +++ b/src/PartSet/PartSet_SketcherReentrantMgr.cpp @@ -359,11 +359,13 @@ void PartSet_SketcherReentrantMgr::onNoMoreWidgets(const std::string& thePreviou return; } - if (module()->sketchMgr()->isDragModeCreation()) - return; - ModuleBase_OperationFeature* aFOperation = dynamic_cast (myWorkshop->currentOperation()); + if (module()->sketchMgr()->isDragModeCreation()) { + if (aFOperation && myIsAutoConstraints) + addConstraints(aFOperation->feature()); + return; + } if (!myWorkshop->module()->getFeatureError(aFOperation->feature()).isEmpty()) return; -- 2.39.2