! * restores the default state of the default application dock widgets (Project Explorer, etc.) */
| 1475 | * restores the default state of the default application dock widgets (Project Explorer, etc.) |
| 1476 | */ |
| 1477 | void MainWin::restoreDefaultDockState() const { |
| 1478 | auto group = Settings::group(QStringLiteral("MainWin")); |
| 1479 | if (group.hasKey(QStringLiteral("DockWidgetState"))) { |
| 1480 | auto state = group.readEntry(QStringLiteral("DockWidgetState"), QByteArray()); |
| 1481 | m_dockManagerMain->restoreState(state); // restore the state of of the default docks |
| 1482 | } else { |
| 1483 | // the state of the dock widgets not available yet, starting for the first time: |
| 1484 | // show the project and properties explorers, hide the worksheet preview. |
| 1485 | // for this, check the actions for the project and properties explorer, uncheck for worksheet preview |
| 1486 | m_projectExplorerDockAction->setChecked(true); |
| 1487 | m_propertiesDockAction->setChecked(true); |
| 1488 | m_worksheetPreviewAction->setChecked(false); |
| 1489 | m_worksheetPreviewDock->toggleView(false); |
| 1490 | } |
| 1491 | } |
| 1492 | |
| 1493 | void MainWin::openProject() { |
| 1494 | bool supportOthers = false; |
nothing calls this directly
no test coverage detected