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

Method activateWorkbench

src/Gui/MainWindow.cpp:1161–1177  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1159}
1160
1161void MainWindow::activateWorkbench(const QString& name)
1162{
1163 // remember workbench by tab (if enabled)
1164
1165 const ParameterGrp::handle hGrp = App::GetApplication().GetParameterGroupByPath(
1166 "User parameter:BaseApp/Preferences/View"
1167 );
1168 const bool saveWB = hGrp->GetBool("SaveWBbyTab", false);
1169 MDIView* view = activeWindow();
1170 if (view && saveWB) {
1171 view->setProperty("ownWB", name);
1172 }
1173
1174 // emit this signal
1175 Q_EMIT workbenchActivated(name);
1176 updateActions(true);
1177}
1178
1179void MainWindow::whatsThis()
1180{

Callers 8

setActiveWindowMethod · 0.95
FreeCADGuiInit.pyFile · 0.45
onLoadClickedMethod · 0.45
showEventMethod · 0.45
showEventMethod · 0.45
exerciseFunction · 0.45

Calls 3

GetBoolMethod · 0.80
setPropertyMethod · 0.45

Tested by

no test coverage detected