Use qGuiApp instead of qApp
As QtQuick applications might not have QApplication.
This commit is contained in:
@@ -135,7 +135,7 @@ void ObjectViewer::dumpWindows()
|
||||
}
|
||||
|
||||
qDebug() << "Top Level Windows:";
|
||||
const auto &topLevelWindows = qApp->topLevelWindows();
|
||||
const auto &topLevelWindows = qGuiApp->topLevelWindows();
|
||||
for (QWindow *w : topLevelWindows) {
|
||||
qDebug() << " QWindow=" << w << "; parent=" << w->parent() << "; transientParent=" << w->transientParent() << "; hwnd=" << w->winId();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user