From: nds Date: Tue, 17 Nov 2015 14:40:47 +0000 (+0300) Subject: #1091 Validate is disabled when Create group X-Git-Tag: V_2.0.0~23 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=4b03dbcea17b4706a4166b99880451701b0f8aef;p=modules%2Fshaper.git #1091 Validate is disabled when Create group 1. deactivate created extrusion sketch in the local sketch selection 2. avoid left of the cross over viewer after contour is closed. --- diff --git a/src/PartSet/PartSet_SketcherMgr.cpp b/src/PartSet/PartSet_SketcherMgr.cpp index 81d1cf6c8..6e600764e 100755 --- a/src/PartSet/PartSet_SketcherMgr.cpp +++ b/src/PartSet/PartSet_SketcherMgr.cpp @@ -75,6 +75,7 @@ #include #include +#include //#define DEBUG_DO_NOT_BY_ENTER @@ -200,10 +201,13 @@ void PartSet_SketcherMgr::onEnterViewPort() #endif if (canChangeCursor(getCurrentOperation())) { + QCursor* aCurrentCursor = QApplication::overrideCursor(); + if (!aCurrentCursor || aCurrentCursor->shape() != Qt::CrossCursor) { + QApplication::setOverrideCursor(QCursor(Qt::CrossCursor)); #ifdef DEBUG_CURSOR - qDebug("onEnterViewPort() : Qt::CrossCursor"); + qDebug("onEnterViewPort() : Qt::CrossCursor"); #endif - QApplication::setOverrideCursor(QCursor(Qt::CrossCursor)); + } } if (!isNestedCreateOperation(getCurrentOperation())) @@ -925,10 +929,13 @@ void PartSet_SketcherMgr::stopSketch(ModuleBase_Operation* theOperation) void PartSet_SketcherMgr::startNestedSketch(ModuleBase_Operation* theOperation) { if (canChangeCursor(theOperation) && myIsMouseOverWindow) { - QApplication::setOverrideCursor(QCursor(Qt::CrossCursor)); + QCursor* aCurrentCursor = QApplication::overrideCursor(); + if (!aCurrentCursor || aCurrentCursor->shape() != Qt::CrossCursor) { + QApplication::setOverrideCursor(QCursor(Qt::CrossCursor)); #ifdef DEBUG_CURSOR - qDebug("startNestedSketch() : Qt::CrossCursor"); + qDebug("startNestedSketch() : Qt::CrossCursor"); #endif + } } } diff --git a/src/PartSet/PartSet_WidgetSketchCreator.cpp b/src/PartSet/PartSet_WidgetSketchCreator.cpp index 6bc043eb4..308dd965f 100644 --- a/src/PartSet/PartSet_WidgetSketchCreator.cpp +++ b/src/PartSet/PartSet_WidgetSketchCreator.cpp @@ -22,6 +22,7 @@ #include #include #include +#include #include #include @@ -32,6 +33,8 @@ #include #include +#include + #include #include #include @@ -228,5 +231,12 @@ void PartSet_WidgetSketchCreator::onResumed(ModuleBase_Operation* theOp) } } } + else { + // this is a workarount to display the feature results in the operation selection mode + // if this is absent, sketch point/line local selection is available on extrusion cut result + static Events_ID anUpdateEvent = Events_Loop::eventByName(EVENT_OBJECT_UPDATED); + ModelAPI_EventCreator::get()->sendUpdated(feature(), anUpdateEvent); + updateObject(feature()); + } } }