diff options
author | Andreas Holzammer <andreas.holzammer@kdab.com> | 2012-07-31 14:00:11 +0200 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-08-01 00:14:41 +0200 |
commit | a0be8ef271bb77c54676625f6f1cbdaf29857196 (patch) | |
tree | ec7f7216110a92c56f12c53c5f9e26249e41d347 /tests/manual | |
parent | b5ad1fcd084d1fa8fe3d0869e119b12d7556857b (diff) |
Add command line options to windowgeometry test
Add -widgetminimized, -widgetmaximized, -widgetfullscreen,
-windowminimized, -windowmaximized, -windowfullscreen
as command line option to test creation of windows in
these modes
Change-Id: If192c131c8996d3b67648427e5784da47ffee971
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Diffstat (limited to 'tests/manual')
-rw-r--r-- | tests/manual/windowgeometry/controllerwidget.cpp | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/tests/manual/windowgeometry/controllerwidget.cpp b/tests/manual/windowgeometry/controllerwidget.cpp index a53739881b..d7fe1523eb 100644 --- a/tests/manual/windowgeometry/controllerwidget.cpp +++ b/tests/manual/windowgeometry/controllerwidget.cpp @@ -442,7 +442,15 @@ ControllerWidget::ControllerWidget(QWidget *parent) } m_testWidget->move(x, y); m_testWidget->resize(200, 200); - m_testWidget->show(); + + if (args.contains(QLatin1String("-widgetminimized"), Qt::CaseInsensitive)) + m_testWidget->showMinimized(); + else if (args.contains(QLatin1String("-widgetmaximized"), Qt::CaseInsensitive)) + m_testWidget->showMaximized(); + else if (args.contains(QLatin1String("-widgetfullscreen"), Qt::CaseInsensitive)) + m_testWidget->showFullScreen(); + else + m_testWidget->show(); #if QT_VERSION >= 0x050000 x += 300; @@ -451,7 +459,14 @@ ControllerWidget::ControllerWidget(QWidget *parent) | Qt::WindowTitleHint); m_testWindow->setFramePos(QPoint(x, y)); m_testWindow->resize(200, 200); - m_testWindow->show(); + if (args.contains(QLatin1String("-windowminimized"), Qt::CaseInsensitive)) + m_testWindow->showMinimized(); + else if (args.contains(QLatin1String("-windowmaximized"), Qt::CaseInsensitive)) + m_testWindow->showMaximized(); + else if (args.contains(QLatin1String("-windowfullscreen"), Qt::CaseInsensitive)) + m_testWindow->showFullScreen(); + else + m_testWindow->show(); m_testWindow->setWindowTitle(tr("TestWindow")); #endif |