From ccbf0560b36515630328be44a20f4fe62eaec531 Mon Sep 17 00:00:00 2001 From: Shawn Rutledge Date: Wed, 27 Mar 2013 09:57:59 +0100 Subject: a nested Window automatically becomes transient for its parent MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit If you declare Window { Window {}} or Window { Item { Window {}}} the inner window will automatically become transient for the outer one. The transient relationship must be set before the inner window becomes visible though, so declaring visible: true doesn't always work, depending on initialization order. It's OK if you assign visible (or call show()) later on when the user needs to see the transient window for the first time. Also added documentation. Change-Id: I888c3b9da6d44d11516227c085bcc12a5ccb5e81 Reviewed-by: Shawn Rutledge Reviewed-by: Jan Arve Sæther --- tests/auto/quick/qquickmousearea/tst_qquickmousearea.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests/auto/quick/qquickmousearea') diff --git a/tests/auto/quick/qquickmousearea/tst_qquickmousearea.cpp b/tests/auto/quick/qquickmousearea/tst_qquickmousearea.cpp index fa33f3f626..a959a60acf 100644 --- a/tests/auto/quick/qquickmousearea/tst_qquickmousearea.cpp +++ b/tests/auto/quick/qquickmousearea/tst_qquickmousearea.cpp @@ -585,7 +585,7 @@ void tst_QQuickMouseArea::pressedCanceledOnWindowDeactivate() QWindow *secondWindow = qvariant_cast(window->rootObject()->property("secondWindow")); secondWindow->setProperty("visible", true); - QTest::qWaitForWindowActive(secondWindow); + QTest::qWaitForWindowExposed(secondWindow); QVERIFY(!window->rootObject()->property("pressed").toBool()); QVERIFY(window->rootObject()->property("canceled").toBool()); -- cgit v1.2.3