hack to allow qWaitForWindowShown to be used in test cases that use QWindow
authorMatthew Cattell <matthew.cattell@nokia.com>
Mon, 12 Sep 2011 15:47:37 +0000 (17:47 +0200)
committerSamuel Rødal <samuel.rodal@nokia.com>
Mon, 12 Sep 2011 19:49:30 +0000 (21:49 +0200)
Change-Id: Id51aaf81d898f9159e4587613f5e34c3de9a5808
Reviewed-on: http://codereview.qt-project.org/4690
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
src/testlib/qtestsystem.h

index de20abe..0165e51 100644 (file)
@@ -45,6 +45,7 @@
 #include <QtTest/qtestcase.h>
 #include <QtCore/qcoreapplication.h>
 #include <QtCore/qelapsedtimer.h>
+#include <QtGui/QWindow>
 
 QT_BEGIN_HEADER
 
@@ -82,6 +83,12 @@ namespace QTest
 #endif
         return true;
     }
+    inline static bool qWaitForWindowShown(QWindow *window)
+    {
+        Q_UNUSED(window);
+        qWait(200);
+        return true;
+    }
 
 }