MCPcopy Create free account
hub / github.com/FreeCAD/FreeCAD / activated

Method activated

src/Mod/TechDraw/Gui/CommandStack.cpp:69–96  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

67}
68
69void CmdTechDrawStackGroup::activated(int iMsg)
70{
71 Gui::TaskView::TaskDialog *dlg = Gui::Control().activeDialog();
72 if (dlg) {
73 QMessageBox::warning(Gui::getMainWindow(), QObject::tr("Task in progress"),
74 QObject::tr("Close the active task dialog and try again."));
75 return;
76 }
77
78 Gui::ActionGroup* pcAction = qobject_cast<Gui::ActionGroup*>(_pcAction);
79 pcAction->setIcon(pcAction->actions().at(iMsg)->icon());
80 switch(iMsg) {
81 case 0:
82 execStackTop(this);
83 break;
84 case 1:
85 execStackBottom(this);
86 break;
87 case 2:
88 execStackUp(this);
89 break;
90 case 3:
91 execStackDown(this);
92 break;
93 default:
94 Base::Console().message("CMD::StackGrp - invalid iMsg: %d\n",iMsg);
95 };
96}
97
98Gui::Action * CmdTechDrawStackGroup::createAction(void)
99{

Callers

nothing calls this directly

Calls 12

warningFunction · 0.85
execStackTopFunction · 0.85
execStackBottomFunction · 0.85
execStackUpFunction · 0.85
execStackDownFunction · 0.85
atMethod · 0.80
actionsMethod · 0.80
getMainWindowFunction · 0.50
activeDialogMethod · 0.45
setIconMethod · 0.45
iconMethod · 0.45
messageMethod · 0.45

Tested by

no test coverage detected