diff options
Diffstat (limited to 'tests/auto/widgets/widgets/qmainwindow/tst_qmainwindow.cpp')
-rw-r--r-- | tests/auto/widgets/widgets/qmainwindow/tst_qmainwindow.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/auto/widgets/widgets/qmainwindow/tst_qmainwindow.cpp b/tests/auto/widgets/widgets/qmainwindow/tst_qmainwindow.cpp index ae71663036..038c468035 100644 --- a/tests/auto/widgets/widgets/qmainwindow/tst_qmainwindow.cpp +++ b/tests/auto/widgets/widgets/qmainwindow/tst_qmainwindow.cpp @@ -43,7 +43,7 @@ #include <qlabel.h> #include <qtextedit.h> #include <qstylehints.h> -#include <qdesktopwidget.h> +#include <qscreen.h> #include <private/qmainwindowlayout_p.h> #include <private/qdockarealayout_p.h> @@ -768,7 +768,7 @@ void tst_QMainWindow::contentsMargins() QFETCH(int, contentsMargin); QMainWindow mw; - const QRect availGeometry = QApplication::desktop()->availableGeometry(); + const QRect availGeometry = QGuiApplication::primaryScreen()->availableGeometry(); mw.menuBar()->addMenu("File"); mw.setWindowTitle(QLatin1String(QTest::currentTestFunction()) + QLatin1Char(' ') + QLatin1String(QTest::currentDataTag())); |