#include <QAction>
#include <QMenu>
+#include <QEvent>
#include <TopoDS.hxx>
#include <BRep_Tool.hxx>
}
if (aPart.get())
aPart->activate();
+ myModule->workshop()->updateCommandStatus();
}
}
if (isNewTransaction) aMgr->startOperation("Activation");
aMgr->setActiveDocument(aMgr->moduleDocument());
if (isNewTransaction) aMgr->finishOperation();
+
+ myModule->workshop()->updateCommandStatus();
}
void PartSet_MenuMgr::grantedOperationIds(ModuleBase_Operation* theOperation,
aSelection.append( aParentFeature );
myModule->workshop()->selection()->setSelectedObjects( aSelection );
}
+
+bool PartSet_MenuMgr::eventFilter(QObject* theObj, QEvent* theEvent)
+{
+ if (theEvent->type() == QEvent::MouseButtonDblClick) {
+ SessionPtr aMgr = ModelAPI_Session::get();
+ if (aMgr->activeDocument() != aMgr->moduleDocument())
+ activatePartSet();
+ }
+ return QObject::eventFilter(theObj, theEvent);
+}
\ No newline at end of file