From 757e2d057345846ba7213e3f7fe84e75d3093331 Mon Sep 17 00:00:00 2001 From: Matthew Cattell Date: Tue, 6 Sep 2011 16:36:01 +0200 Subject: fixed to work with qsgcanvas MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: Ia044bb738469fdd2c9ecc6154ac51851db3e0e7f Reviewed-on: http://codereview.qt.nokia.com/4270 Reviewed-by: Samuel Rødal --- tests/auto/declarative/qsgitem/tst_qsgitem.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'tests') 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 #include "private/qsgfocusscope_p.h" #include "../../../shared/util.h" #include @@ -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 -- cgit v1.2.3