ModuleBase_Operation* anOperation = myModule->workshop()->currentOperation();
if (!PartSet_SketcherMgr::isSketchOperation(anOperation) &&
- !PartSet_SketcherMgr::isNestedSketchOperation(anOperation))
+ !PartSet_SketcherMgr::isNestedSketchOperation(anOperation,
+ myModule->sketchMgr()->activeSketch()))
return false;
myCoinsideLines.clear();
ModuleBase_Operation* anOperation = myModule->workshop()->currentOperation();
bool isActiveSketch = PartSet_SketcherMgr::isSketchOperation(anOperation) ||
- PartSet_SketcherMgr::isNestedSketchOperation(anOperation);
+ PartSet_SketcherMgr::isNestedSketchOperation(anOperation,
+ myModule->sketchMgr()->activeSketch());
if (isActiveSketch) {
theStdActions["WIREFRAME_CMD"]->setEnabled(false);
theStdActions["SHADING_CMD"]->setEnabled(false);
{
ModuleBase_Operation* anOperation = myModule->workshop()->currentOperation();
+ CompositeFeaturePtr aSketch = myModule->sketchMgr()->activeSketch();
bool isActiveSketch = PartSet_SketcherMgr::isSketchOperation(anOperation) ||
- PartSet_SketcherMgr::isNestedSketchOperation(anOperation);
+ PartSet_SketcherMgr::isNestedSketchOperation(anOperation, aSketch);
if (!isActiveSketch)
return;
QObjectPtrList anObjects;
bool isUseTransaction = false;
// 1. change auxiliary type of a created feature
- if (PartSet_SketcherMgr::isNestedCreateOperation(anOperation) &&
+ if (PartSet_SketcherMgr::isNestedCreateOperation(anOperation, aSketch) &&
PartSet_SketcherMgr::isEntity(anOperation->id().toStdString()) ) {
ModuleBase_OperationFeature* aFOperation = dynamic_cast<ModuleBase_OperationFeature*>
(anOperation);
bool anEnabled = false;
ModuleBase_Operation* anOperation = myModule->workshop()->currentOperation();
+ CompositeFeaturePtr aSketch = myModule->sketchMgr()->activeSketch();
bool isActiveSketch = PartSet_SketcherMgr::isSketchOperation(anOperation) ||
- PartSet_SketcherMgr::isNestedSketchOperation(anOperation);
+ PartSet_SketcherMgr::isNestedSketchOperation(anOperation, aSketch);
if (!isActiveSketch)
return anEnabled;
QObjectPtrList anObjects;
// 1. change auxiliary type of a created feature
- if (PartSet_SketcherMgr::isNestedCreateOperation(anOperation) &&
+ if (PartSet_SketcherMgr::isNestedCreateOperation(anOperation, aSketch) &&
PartSet_SketcherMgr::isEntity(anOperation->id().toStdString()) ) {
ModuleBase_OperationFeature* aFOperation = dynamic_cast<ModuleBase_OperationFeature*>(anOperation);
if (aFOperation)
else {
/// The operation should not be aborted here, because the method does not changed
/// the auxilliary state, but checks the possibility to perform this
- ///if (PartSet_SketcherMgr::isNestedSketchOperation(anOperation))
+ ///if (PartSet_SketcherMgr::isNestedSketchOperation(anOperation,
+ // myModule->sketchMgr()->activeSketch()))
/// anOperation->abort();
// 2. change auxiliary type of selected sketch entities
ModuleBase_ISelection* aSelection = myModule->workshop()->selection();