-void PartSet_Module::createActions()
-{
- QAction* anAction;
-
- anAction = new QAction(tr("Auxiliary"), this);
- anAction->setCheckable(true);
- addAction("AUXILIARY_CMD", anAction);
-}
-
-QAction* PartSet_Module::action(const QString& theId) const
-{
- if (myActions.contains(theId))
- return myActions[theId];
- return 0;
-}
-
-void PartSet_Module::addAction(const QString& theId, QAction* theAction)
-{
- if (myActions.contains(theId))
- qCritical("A command with Id = '%s' already defined!", qPrintable(theId));
- theAction->setData(theId);
- connect(theAction, SIGNAL(triggered(bool)), this, SLOT(onAction(bool)));
- myActions[theId] = theAction;
-}
-
-void PartSet_Module::onAction(bool isChecked)
-{
- QAction* aAction = static_cast<QAction*>(sender());
- QString anId = aAction->data().toString();
-
- if (anId == "AUXILIARY_CMD") {
- mySketchMgr->setAuxiliary(isChecked);
- }
-}