QQuickScreen is exposed as an attached property on Window too
authorShawn Rutledge <shawn.rutledge@digia.com>
Mon, 18 Feb 2013 15:48:24 +0000 (16:48 +0100)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Wed, 20 Feb 2013 10:16:49 +0000 (11:16 +0100)
Change-Id: I13ee75247cbe6238de1b58cf0005c39fc4314e96
Reviewed-by: Alan Alpert <aalpert@rim.com>

src/quick/items/qquickscreen.cpp

index 7c7d8a6..3ab93e6 100644 (file)
@@ -112,6 +112,10 @@ QQuickScreenAttached::QQuickScreenAttached(QObject* attachee)
 
         if (m_attachee->window()) //It might not be assigned to a window yet
             windowChanged(m_attachee->window());
+    } else {
+        QQuickWindow *window = qobject_cast<QQuickWindow*>(attachee);
+        if (window)
+            windowChanged(window);
     }
 }