aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorMatthew Cattell <matthew.cattell@nokia.com>2011-09-06 16:36:01 +0200
committerSamuel Rødal <samuel.rodal@nokia.com>2011-09-06 16:38:00 +0200
commit757e2d057345846ba7213e3f7fe84e75d3093331 (patch)
tree92814d763a79196ed6484c2f13f36c723bb231a5 /tests
parentfa19b6b5b81b44047a1e9ca574fbce13bc38c7a5 (diff)
fixed to work with qsgcanvas
Change-Id: Ia044bb738469fdd2c9ecc6154ac51851db3e0e7f Reviewed-on: http://codereview.qt.nokia.com/4270 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/declarative/qsgitem/tst_qsgitem.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/auto/declarative/qsgitem/tst_qsgitem.cpp b/tests/auto/declarative/qsgitem/tst_qsgitem.cpp
index 05e59a69f0..99c1cf6b5b 100644
--- a/tests/auto/declarative/qsgitem/tst_qsgitem.cpp
+++ b/tests/auto/declarative/qsgitem/tst_qsgitem.cpp
@@ -43,6 +43,7 @@
#include "qsgitem.h"
#include "qsgcanvas.h"
+#include <QtWidgets/QGraphicsSceneMouseEvent>
#include "private/qsgfocusscope_p.h"
#include "../../../shared/util.h"
#include <QDebug>
@@ -132,9 +133,10 @@ private slots:
void hoverEventInParent();
private:
- void ensureFocus(QWidget *w) {
+
+ void ensureFocus(QWindow *w) {
w->show();
- qApp->setActiveWindow(w);
+ w->requestActivateWindow();
qApp->processEvents();
#ifdef Q_WS_X11