ProjectExplorer: Fix project mode layout issue

Window state save/restore was undermined by code that added and removed
the central widget, leading to inconsistent data.
Fix this by making sure that we (de-)serialize if and only if a central
widget is present.
Also remove the hacky workaround that was supposed to fix this, but
didn't.

Fixes: QTCREATORBUG-25551
Change-Id: I6e7f2aff7455db476f870ead64b09a9716f3558b
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
This commit is contained in:
Christian Kandeler
2021-05-04 14:36:47 +02:00
parent 0a84406e0d
commit 97744a071a
2 changed files with 8 additions and 3 deletions

View File

@@ -55,6 +55,7 @@ class ProjectWindowPrivate;
class ProjectWindow : public Utils::FancyMainWindow
{
friend class ProjectWindowPrivate;
Q_OBJECT
public: