| 1040 | } |
| 1041 | |
| 1042 | void Controller::initRightspaceWidget() |
| 1043 | { |
| 1044 | if (d->rightspace) |
| 1045 | return; |
| 1046 | |
| 1047 | d->rightspace = new WorkspaceWidget(d->mainWindow); |
| 1048 | |
| 1049 | WidgetInfo info; |
| 1050 | info.name = WN_RIGHTSPACE; |
| 1051 | info.setWidget(d->rightspace); |
| 1052 | info.defaultPos = Position::Right; |
| 1053 | info.replace = true; |
| 1054 | info.icon = QIcon::fromTheme("uc_right_show"); |
| 1055 | d->allWidgets.insert(WN_RIGHTSPACE, info); |
| 1056 | |
| 1057 | d->showRightspaceBtn = createDockButton(info); |
| 1058 | d->showRightspaceBtn->setChecked(true); |
| 1059 | auto scAction = new QAction(tr("Open rightspace"), d->rightspace); |
| 1060 | auto cmd = ActionManager::instance()->registerAction(scAction, "Core.Open.Rightspace"); |
| 1061 | cmd->setDefaultKeySequence(QKeySequence(Qt::ALT + Qt::Key_L)); |
| 1062 | connect(scAction, &QAction::triggered, d->showRightspaceBtn, &DToolButton::clicked); |
| 1063 | |
| 1064 | d->statusBar->insertPermanentWidget(0, d->showRightspaceBtn); |
| 1065 | } |
| 1066 | |
| 1067 | void Controller::initTopToolBar() |
| 1068 | { |
nothing calls this directly
no test coverage detected