┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/dolphinmainwindow.cpp
diff options
context:
space:
mode:
authorEugene Popov <[email protected]>2021-09-28 19:39:52 +0000
committerNate Graham <[email protected]>2021-09-28 19:39:52 +0000
commitfa8d9de4d866070acadd57178d20144bb5e62a0a (patch)
tree92c942b6c6de05d103d239d3f44db0a716aa8f2a /src/dolphinmainwindow.cpp
parent8bf64cf8b15f390ab9a76f304dc22438b258556f (diff)
Fix closing a secondary viewContainer on startup settings change
Apply split view settings only when changing the corresponding option. BUG: 426221 FIXED-IN: 21.08.2
Diffstat (limited to 'src/dolphinmainwindow.cpp')
-rw-r--r--src/dolphinmainwindow.cpp14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/dolphinmainwindow.cpp b/src/dolphinmainwindow.cpp
index 0d8438075..3966a08fe 100644
--- a/src/dolphinmainwindow.cpp
+++ b/src/dolphinmainwindow.cpp
@@ -216,6 +216,9 @@ DolphinMainWindow::DolphinMainWindow() :
showErrorMessage(errorMessage);
});
#endif
+
+ connect(GeneralSettings::self(), &GeneralSettings::splitViewChanged,
+ this, &DolphinMainWindow::slotSplitViewChanged);
}
DolphinMainWindow::~DolphinMainWindow()
@@ -439,6 +442,12 @@ void DolphinMainWindow::openNewTab(const QUrl& url)
m_tabWidget->openNewTab(url, QUrl());
}
+void DolphinMainWindow::slotSplitViewChanged()
+{
+ m_tabWidget->currentTabPage()->setSplitViewEnabled(GeneralSettings::splitView(), WithAnimation);
+ updateSplitAction();
+}
+
void DolphinMainWindow::openInNewTab()
{
const KFileItemList& list = m_activeViewContainer->view()->selectedItems();
@@ -2096,11 +2105,6 @@ void DolphinMainWindow::refreshViews()
m_tabWidget->refreshViews();
if (GeneralSettings::modifiedStartupSettings()) {
- // The startup settings have been changed by the user (see bug #254947).
- // Synchronize the split-view setting with the active view:
- const bool splitView = GeneralSettings::splitView();
- m_tabWidget->currentTabPage()->setSplitViewEnabled(splitView, WithAnimation);
- updateSplitAction();
updateWindowTitle();
}