diff options
| author | Egor Maksimov <[email protected]> | 2026-01-28 09:16:35 +0000 |
|---|---|---|
| committer | Méven Car <[email protected]> | 2026-01-28 09:16:35 +0000 |
| commit | ad73de758fc1b2c5a48004adfb06559732cc305e (patch) | |
| tree | eaa7f41f7b670ddc42ce557acefd7f7923a7b957 /src/dolphinmainwindow.cpp | |
| parent | 3ca892a70f0baf97c64ef87911dba502450184cf (diff) | |
panel/terminal: Add ability to disable konsole url sync
Sometimes when you work on the project using the build in konsole, most commands are meant to be run at the project root. This allows for user to disable URL sync so that one could browse the project tree without constantly needing go back to the root folder just to run a command.
BUG: 306381
Diffstat (limited to 'src/dolphinmainwindow.cpp')
| -rw-r--r-- | src/dolphinmainwindow.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/dolphinmainwindow.cpp b/src/dolphinmainwindow.cpp index 2ad1cc8e3..62ff2fa45 100644 --- a/src/dolphinmainwindow.cpp +++ b/src/dolphinmainwindow.cpp @@ -2498,6 +2498,17 @@ void DolphinMainWindow::setupDockWidgets() focusTerminalPanel->setIcon(QIcon::fromTheme(QStringLiteral("swap-panels"))); actionCollection()->setDefaultShortcut(focusTerminalPanel, Qt::CTRL | Qt::SHIFT | Qt::Key_F4); connect(focusTerminalPanel, &QAction::triggered, this, &DolphinMainWindow::toggleTerminalPanelFocus); + + QAction *switchTerminalUrlSync = actionCollection()->addAction(QStringLiteral("switch_terminal_url_sync")); + switchTerminalUrlSync->setText(i18nc("@action:inmenu", "Follow Directory Switch")); + switchTerminalUrlSync->setToolTip( + i18nc("@info:tooltip", "Determines if current working directory must be kept in sync with terminal whenever directory is changed.")); + switchTerminalUrlSync->setCheckable(true); + connect(switchTerminalUrlSync, &QAction::toggled, m_terminalPanel, &TerminalPanel::switchSync); + switchTerminalUrlSync->setChecked(true); + + m_terminalPanel->setSwitchTerminalUrlSyncAction(switchTerminalUrlSync); + } // endif "shell_access" allowed #endif // HAVE_TERMINAL |
