┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/dolphinmainwindow.cpp
diff options
context:
space:
mode:
authorNate Graham <[email protected]>2021-04-22 18:06:06 -0600
committerMéven Car <[email protected]>2021-05-05 03:50:44 +0000
commitc836cf010c12858a7f3a4943c06f9de2b9f31a14 (patch)
tree61c38be364a4149650812ea249acd6de029c43f4 /src/dolphinmainwindow.cpp
parenta6ec74a82c2f31a7eda0a7ba562c8f6bd77b1421 (diff)
Set initial size corectly
The resize() that we do to set the initial size is working around a bug in frameworks that is going to be fixed soon. See https://invent.kde.org/frameworks/kxmlgui/-/merge_requests/53.
Diffstat (limited to 'src/dolphinmainwindow.cpp')
-rw-r--r--src/dolphinmainwindow.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/dolphinmainwindow.cpp b/src/dolphinmainwindow.cpp
index 80c6aa320..e9c0c3813 100644
--- a/src/dolphinmainwindow.cpp
+++ b/src/dolphinmainwindow.cpp
@@ -178,8 +178,6 @@ DolphinMainWindow::DolphinMainWindow() :
if (firstRun) {
menuBar()->setVisible(false);
- // Assure a proper default size if Dolphin runs the first time
- resize(760, 550);
}
const bool showMenu = !menuBar()->isHidden();
@@ -2412,6 +2410,12 @@ bool DolphinMainWindow::eventFilter(QObject* obj, QEvent* event)
return false;
}
+// Set a sane initial window size
+QSize DolphinMainWindow::sizeHint() const
+{
+ return KXmlGuiWindow::sizeHint().expandedTo(QSize(760, 550));
+}
+
void DolphinMainWindow::saveNewToolbarConfig()
{
KXmlGuiWindow::saveNewToolbarConfig(); // Applies the new config. This has to be called first