File tree Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -542,7 +542,8 @@ void ProxyWindowAttached::updateWindow() {
542542void ProxyWindowAttached::setWindow (ProxyWindowBase* window) {
543543 if (window == this ->mWindow ) return ;
544544 this ->mWindow = window;
545- this ->mWindowInterface = window ? qobject_cast<WindowInterface*>(window->parent ()) : nullptr ;
545+ auto * parentInterface = window ? qobject_cast<WindowInterface*>(window->parent ()) : nullptr ;
546+ this ->mWindowInterface = parentInterface ? static_cast <QObject*>(parentInterface) : window;
546547 emit this ->windowChanged ();
547548}
548549
Original file line number Diff line number Diff line change @@ -220,7 +220,7 @@ class ProxyWindowAttached: public QsWindowAttached {
220220
221221private:
222222 ProxyWindowBase* mWindow = nullptr ;
223- WindowInterface * mWindowInterface = nullptr ;
223+ QObject * mWindowInterface = nullptr ;
224224
225225 void setWindow (ProxyWindowBase* window);
226226};
You can’t perform that action at this time.
0 commit comments