Call update only if the item has the ItemHasContent Flag set
authorMartin Zielinski <martin.zielinski@nokia.com>
Tue, 21 Jun 2011 11:29:49 +0000 (13:29 +0200)
committerMartin Zielinski <martin.zielinski@nokia.com>
Tue, 21 Jun 2011 11:29:49 +0000 (13:29 +0200)
src/qt-compositor/compositor_api/waylandsurfaceitem.cpp

index cf930e1..0a41c55 100644 (file)
@@ -219,5 +219,8 @@ QSGNode *WaylandSurfaceItem::updatePaintNode(QSGNode *oldNode, UpdatePaintNodeDa
 void WaylandSurfaceItem::setUseTextureAlpha(bool useTextureAlpha)
 {
     m_useTextureAlpha = useTextureAlpha;
-    update();
+
+    if ((flags() & ItemHasContents) != 0) {
+        update();
+    }
 }