diff options
| author | Elvis Angelaccio <[email protected]> | 2018-01-21 12:18:21 +0100 |
|---|---|---|
| committer | Elvis Angelaccio <[email protected]> | 2018-02-10 19:40:15 +0100 |
| commit | 87e8d0ba5f80f53a62a3951537b60a24e72e8460 (patch) | |
| tree | 902623094659c880fe2a29c8632464490e3a9d13 /src/dolphinmainwindow.cpp | |
| parent | 9fbf7a0b624aee6b116efdf69462e73f0275fab6 (diff) | |
Build TerminalPanel also on Windows
Summary:
terminalpanel.cpp *should* compile on Windows, so there is no reason to
remove it from the build and use tons of #ifdefs in dolphinmainwindow.
We still keep the terminal panel disabled on Windows
(i.e. the two remaining #ifndef Q_OS_WIN in dolphinmainwindow),
because it is probably not functional.
But at least we won't break the Windows CI every time
someone touches the terminal panel code (see e.g. 2e942237c9).
Test Plan: Builds on Linux, someone on Windows should test this patch if possible.
Reviewers: #dolphin, #craft
Differential Revision: https://phabricator.kde.org/D10006
Diffstat (limited to 'src/dolphinmainwindow.cpp')
| -rw-r--r-- | src/dolphinmainwindow.cpp | 15 |
1 files changed, 1 insertions, 14 deletions
diff --git a/src/dolphinmainwindow.cpp b/src/dolphinmainwindow.cpp index d3e2fd907..da241e20e 100644 --- a/src/dolphinmainwindow.cpp +++ b/src/dolphinmainwindow.cpp @@ -33,6 +33,7 @@ #include "panels/folders/folderspanel.h" #include "panels/places/placespanel.h" #include "panels/information/informationpanel.h" +#include "panels/terminal/terminalpanel.h" #include "settings/dolphinsettingsdialog.h" #include "statusbar/dolphinstatusbar.h" #include "views/dolphinviewactionhandler.h" @@ -41,10 +42,6 @@ #include "views/viewproperties.h" #include "views/dolphinnewfilemenuobserver.h" -#ifndef Q_OS_WIN -#include "panels/terminal/terminalpanel.h" -#endif - #include "dolphin_generalsettings.h" #include <KActionCollection> @@ -100,9 +97,7 @@ DolphinMainWindow::DolphinMainWindow() : m_controlButton(nullptr), m_updateToolBarTimer(nullptr), m_lastHandleUrlStatJob(nullptr), -#ifndef Q_OS_WIN m_terminalPanel(nullptr), -#endif m_placesPanel(nullptr), m_tearDownFromPlacesRequested(false) { @@ -631,11 +626,9 @@ void DolphinMainWindow::togglePanelLockState() void DolphinMainWindow::slotTerminalPanelVisibilityChanged() { -#ifndef Q_OS_WIN if (m_terminalPanel->isHiddenInVisibleWindow()) { m_activeViewContainer->view()->setFocus(); } -#endif } void DolphinMainWindow::goBack() @@ -1025,7 +1018,6 @@ void DolphinMainWindow::setUrlAsCaption(const QUrl& url) void DolphinMainWindow::slotStorageTearDownFromPlacesRequested(const QString& mountPath) { -#ifndef Q_OS_WIN if (m_terminalPanel->currentWorkingDirectory().startsWith(mountPath)) { m_tearDownFromPlacesRequested = true; m_terminalPanel->goHome(); @@ -1033,17 +1025,14 @@ void DolphinMainWindow::slotStorageTearDownFromPlacesRequested(const QString& mo } else { m_placesPanel->proceedWithTearDown(); } -#endif } void DolphinMainWindow::slotStorageTearDownExternallyRequested(const QString& mountPath) { -#ifndef Q_OS_WIN if (m_terminalPanel->currentWorkingDirectory().startsWith(mountPath)) { m_tearDownFromPlacesRequested = false; m_terminalPanel->goHome(); } -#endif } void DolphinMainWindow::setupActions() @@ -1368,9 +1357,7 @@ void DolphinMainWindow::setupDockWidgets() panelsMenu->addAction(ac->action(QStringLiteral("show_places_panel"))); panelsMenu->addAction(ac->action(QStringLiteral("show_information_panel"))); panelsMenu->addAction(ac->action(QStringLiteral("show_folders_panel"))); -#ifndef Q_OS_WIN panelsMenu->addAction(ac->action(QStringLiteral("show_terminal_panel"))); -#endif panelsMenu->addSeparator(); panelsMenu->addAction(lockLayoutAction); } |
