From e085e19066c6a157f64761cadd3e098cbdc3e5db Mon Sep 17 00:00:00 2001 From: nds Date: Tue, 3 Nov 2015 16:54:26 +0300 Subject: [PATCH] Cross cursor processing in the 'internal' edit operation. --- src/PartSet/PartSet_SketcherMgr.cpp | 2 +- src/PartSet/PartSet_SketcherReetntrantMgr.cpp | 5 +++++ src/PartSet/PartSet_SketcherReetntrantMgr.h | 3 +++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/src/PartSet/PartSet_SketcherMgr.cpp b/src/PartSet/PartSet_SketcherMgr.cpp index fb0d9bb39..601ca3337 100755 --- a/src/PartSet/PartSet_SketcherMgr.cpp +++ b/src/PartSet/PartSet_SketcherMgr.cpp @@ -924,7 +924,7 @@ void PartSet_SketcherMgr::stopNestedSketch(ModuleBase_Operation* theOp) { myIsMouseOverViewProcessed = true; operationMgr()->onValidateOperation(); - if (isNestedCreateOperation(theOp)) + if (isNestedCreateOperation(theOp) || myModule->sketchReentranceMgr()->isInternalEditActive()) QApplication::restoreOverrideCursor(); } diff --git a/src/PartSet/PartSet_SketcherReetntrantMgr.cpp b/src/PartSet/PartSet_SketcherReetntrantMgr.cpp index 61284fd7b..0bb3ce4de 100755 --- a/src/PartSet/PartSet_SketcherReetntrantMgr.cpp +++ b/src/PartSet/PartSet_SketcherReetntrantMgr.cpp @@ -53,6 +53,11 @@ ModuleBase_ModelWidget* PartSet_SketcherReetntrantMgr::internalActiveWidget() co return aWidget; } +bool PartSet_SketcherReetntrantMgr::isInternalEditActive() const +{ + return myIsInternalEditOperation; +} + bool PartSet_SketcherReetntrantMgr::operationCommitted(ModuleBase_Operation* theOperation) { bool aProcessed = false; diff --git a/src/PartSet/PartSet_SketcherReetntrantMgr.h b/src/PartSet/PartSet_SketcherReetntrantMgr.h index 156de40d9..c43796693 100755 --- a/src/PartSet/PartSet_SketcherReetntrantMgr.h +++ b/src/PartSet/PartSet_SketcherReetntrantMgr.h @@ -51,6 +51,9 @@ public: /// or return null. If the current widget of the operation is a viewer selector, it returns null. ModuleBase_ModelWidget* internalActiveWidget() const; + /// Return true if the current edit operation is an internal + bool isInternalEditActive() const; + /// if the internal flags allow it and the manager is active, it starts an internal edit operation /// for the created operation. /// \param thePreviousAttributeID an index of the previous active attribute -- 2.39.2