DesignModeContext: Don't leak context on shutdown

Make passed widget a parent of the context.

Fixes: QTCREATORBUG-27570
Change-Id: Ifbc9db8d5b3fb95566e2c6b83df9c10d02f7c0e5
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
Jarek Kobus
2022-06-30 13:46:00 +02:00
parent f27eb94669
commit a85fa172c2

View File

@@ -39,7 +39,7 @@ class DesignModeContext : public Core::IContext
Q_OBJECT Q_OBJECT
public: public:
DesignModeContext(QWidget *widget) { setWidget(widget); } DesignModeContext(QWidget *widget) : Core::IContext(widget) { setWidget(widget); }
}; };
class QdsLandingPageWidget : public QWidget class QdsLandingPageWidget : public QWidget