Changeset View
Changeset View
Standalone View
Standalone View
src/dolphinmainwindow.cpp
Show First 20 Lines • Show All 1260 Lines • ▼ Show 20 Line(s) | 1253 | { | |||
---|---|---|---|---|---|
1261 | lockLayoutAction->setActive(lock); | 1261 | lockLayoutAction->setActive(lock); | ||
1262 | connect(lockLayoutAction, &KDualAction::triggered, this, &DolphinMainWindow::togglePanelLockState); | 1262 | connect(lockLayoutAction, &KDualAction::triggered, this, &DolphinMainWindow::togglePanelLockState); | ||
1263 | 1263 | | |||
1264 | // Setup "Information" | 1264 | // Setup "Information" | ||
1265 | DolphinDockWidget* infoDock = new DolphinDockWidget(i18nc("@title:window", "Information")); | 1265 | DolphinDockWidget* infoDock = new DolphinDockWidget(i18nc("@title:window", "Information")); | ||
1266 | infoDock->setLocked(lock); | 1266 | infoDock->setLocked(lock); | ||
1267 | infoDock->setObjectName(QStringLiteral("infoDock")); | 1267 | infoDock->setObjectName(QStringLiteral("infoDock")); | ||
1268 | infoDock->setAllowedAreas(Qt::LeftDockWidgetArea | Qt::RightDockWidgetArea); | 1268 | infoDock->setAllowedAreas(Qt::LeftDockWidgetArea | Qt::RightDockWidgetArea); | ||
1269 | | ||||
1270 | #ifdef HAVE_BALOO | ||||
1269 | InformationPanel* infoPanel = new InformationPanel(infoDock); | 1271 | InformationPanel* infoPanel = new InformationPanel(infoDock); | ||
1270 | infoPanel->setCustomContextMenuActions({lockLayoutAction}); | 1272 | infoPanel->setCustomContextMenuActions({lockLayoutAction}); | ||
1271 | connect(infoPanel, &InformationPanel::urlActivated, this, &DolphinMainWindow::handleUrl); | 1273 | connect(infoPanel, &InformationPanel::urlActivated, this, &DolphinMainWindow::handleUrl); | ||
1272 | infoDock->setWidget(infoPanel); | 1274 | infoDock->setWidget(infoPanel); | ||
1273 | 1275 | | |||
1274 | QAction* infoAction = infoDock->toggleViewAction(); | 1276 | QAction* infoAction = infoDock->toggleViewAction(); | ||
1275 | createPanelAction(QIcon::fromTheme(QStringLiteral("dialog-information")), Qt::Key_F11, infoAction, QStringLiteral("show_information_panel")); | 1277 | createPanelAction(QIcon::fromTheme(QStringLiteral("dialog-information")), Qt::Key_F11, infoAction, QStringLiteral("show_information_panel")); | ||
1276 | 1278 | | |||
1277 | addDockWidget(Qt::RightDockWidgetArea, infoDock); | 1279 | addDockWidget(Qt::RightDockWidgetArea, infoDock); | ||
1278 | connect(this, &DolphinMainWindow::urlChanged, | 1280 | connect(this, &DolphinMainWindow::urlChanged, | ||
1279 | infoPanel, &InformationPanel::setUrl); | 1281 | infoPanel, &InformationPanel::setUrl); | ||
1280 | connect(this, &DolphinMainWindow::selectionChanged, | 1282 | connect(this, &DolphinMainWindow::selectionChanged, | ||
1281 | infoPanel, &InformationPanel::setSelection); | 1283 | infoPanel, &InformationPanel::setSelection); | ||
1282 | connect(this, &DolphinMainWindow::requestItemInfo, | 1284 | connect(this, &DolphinMainWindow::requestItemInfo, | ||
1283 | infoPanel, &InformationPanel::requestDelayedItemInfo); | 1285 | infoPanel, &InformationPanel::requestDelayedItemInfo); | ||
1286 | #endif | ||||
1284 | 1287 | | |||
1285 | // Setup "Folders" | 1288 | // Setup "Folders" | ||
1286 | DolphinDockWidget* foldersDock = new DolphinDockWidget(i18nc("@title:window", "Folders")); | 1289 | DolphinDockWidget* foldersDock = new DolphinDockWidget(i18nc("@title:window", "Folders")); | ||
1287 | foldersDock->setLocked(lock); | 1290 | foldersDock->setLocked(lock); | ||
1288 | foldersDock->setObjectName(QStringLiteral("foldersDock")); | 1291 | foldersDock->setObjectName(QStringLiteral("foldersDock")); | ||
1289 | foldersDock->setAllowedAreas(Qt::LeftDockWidgetArea | Qt::RightDockWidgetArea); | 1292 | foldersDock->setAllowedAreas(Qt::LeftDockWidgetArea | Qt::RightDockWidgetArea); | ||
1290 | FoldersPanel* foldersPanel = new FoldersPanel(foldersDock); | 1293 | FoldersPanel* foldersPanel = new FoldersPanel(foldersDock); | ||
1291 | foldersPanel->setCustomContextMenuActions({lockLayoutAction}); | 1294 | foldersPanel->setCustomContextMenuActions({lockLayoutAction}); | ||
▲ Show 20 Lines • Show All 333 Lines • Show Last 20 Lines |