Title: [105906] trunk
Revision
105906
Author
[email protected]
Date
2012-01-25 11:53:05 -0800 (Wed, 25 Jan 2012)

Log Message

Fix the semantics of passing contentsVisible flag to GraphicsLayers
https://bugs.webkit.org/show_bug.cgi?id=76975

Reviewed by Simon Fraser.

Source/WebCore:

This patch is covered by existing tests, in particular
compositing/visibility/layer-visible-content.html; its
expectations are rebaselined.

* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):

LayoutTests:

* compositing/visibility/layer-visible-content-expected.txt: rebaselined expectations.
* compositing/visibility/visibility-image-layers-dynamic-expected.txt: rebaselined expectations.
* platform/chromium/test_expectations.txt: removed the expectation that the test fails on chromium, it should pass now.

Modified Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (105905 => 105906)


--- trunk/LayoutTests/ChangeLog	2012-01-25 19:43:06 UTC (rev 105905)
+++ trunk/LayoutTests/ChangeLog	2012-01-25 19:53:05 UTC (rev 105906)
@@ -1,3 +1,14 @@
+2012-01-25  Shawn Singh  <[email protected]>
+
+        Fix the semantics of passing contentsVisible flag to GraphicsLayers
+        https://bugs.webkit.org/show_bug.cgi?id=76975
+
+        Reviewed by Simon Fraser.
+
+        * compositing/visibility/layer-visible-content-expected.txt: rebaselined expectations.
+        * compositing/visibility/visibility-image-layers-dynamic-expected.txt: rebaselined expectations.
+        * platform/chromium/test_expectations.txt: removed the expectation that the test fails on chromium, it should pass now.
+
 2012-01-25  MORITA Hajime  <[email protected]>
 
         Unreviewed test fix to followup r105900.

Modified: trunk/LayoutTests/compositing/visibility/layer-visible-content-expected.txt (105905 => 105906)


--- trunk/LayoutTests/compositing/visibility/layer-visible-content-expected.txt	2012-01-25 19:43:06 UTC (rev 105905)
+++ trunk/LayoutTests/compositing/visibility/layer-visible-content-expected.txt	2012-01-25 19:53:05 UTC (rev 105906)
@@ -3,11 +3,10 @@
   (children 1
     (GraphicsLayer
       (bounds 800.00 600.00)
-      (children 1
+      (children 2
         (GraphicsLayer
           (bounds 200.00 200.00)
           (drawsContent 1)
-          (contentsVisible 0)
           (children 1
             (GraphicsLayer
               (bounds 200.00 200.00)
@@ -19,6 +18,11 @@
             )
           )
         )
+        (GraphicsLayer
+          (bounds 800.00 15.00)
+          (opacity 0.00)
+          (drawsContent 1)
+        )
       )
     )
   )

Modified: trunk/LayoutTests/compositing/visibility/visibility-image-layers-dynamic-expected.txt (105905 => 105906)


--- trunk/LayoutTests/compositing/visibility/visibility-image-layers-dynamic-expected.txt	2012-01-25 19:43:06 UTC (rev 105905)
+++ trunk/LayoutTests/compositing/visibility/visibility-image-layers-dynamic-expected.txt	2012-01-25 19:53:05 UTC (rev 105906)
@@ -35,7 +35,6 @@
         (GraphicsLayer
           (position 14.00 314.00)
           (bounds 757.00 152.00)
-          (contentsVisible 0)
           (children 1
             (GraphicsLayer
               (position 20.00 20.00)
@@ -50,10 +49,10 @@
 After step 1
 
 (GraphicsLayer
-  (bounds 785.00 1301.00)
+  (bounds 785.00 1286.00)
   (children 1
     (GraphicsLayer
-      (bounds 785.00 1301.00)
+      (bounds 785.00 1286.00)
       (children 3
         (GraphicsLayer
           (position 14.00 6.00)
@@ -80,7 +79,6 @@
         (GraphicsLayer
           (position 14.00 314.00)
           (bounds 757.00 152.00)
-          (contentsVisible 0)
           (children 1
             (GraphicsLayer
               (position 20.00 20.00)
@@ -95,10 +93,10 @@
 After step 2
 
 (GraphicsLayer
-  (bounds 785.00 1965.00)
+  (bounds 785.00 1935.00)
   (children 1
     (GraphicsLayer
-      (bounds 785.00 1965.00)
+      (bounds 785.00 1935.00)
       (children 3
         (GraphicsLayer
           (position 14.00 6.00)
@@ -124,7 +122,6 @@
         (GraphicsLayer
           (position 14.00 314.00)
           (bounds 757.00 152.00)
-          (contentsVisible 0)
           (children 1
             (GraphicsLayer
               (position 20.00 20.00)

Modified: trunk/LayoutTests/platform/chromium/test_expectations.txt (105905 => 105906)


--- trunk/LayoutTests/platform/chromium/test_expectations.txt	2012-01-25 19:43:06 UTC (rev 105905)
+++ trunk/LayoutTests/platform/chromium/test_expectations.txt	2012-01-25 19:53:05 UTC (rev 105906)
@@ -4004,8 +4004,6 @@
 // Need to implement file name logging.
 BUGWK76572 : http/tests/download = FAIL
 
-BUGWK76716 : compositing/visibility/layer-visible-content.html = IMAGE+TEXT
-
 BUGWK76967 : media/media-fragments/TC0030-TC0039.html = PASS TIMEOUT
 
 BUGABARTH : media/audio-garbage-collect.html = PASS FAIL

Modified: trunk/Source/WebCore/ChangeLog (105905 => 105906)


--- trunk/Source/WebCore/ChangeLog	2012-01-25 19:43:06 UTC (rev 105905)
+++ trunk/Source/WebCore/ChangeLog	2012-01-25 19:53:05 UTC (rev 105906)
@@ -1,3 +1,17 @@
+2012-01-25  Shawn Singh  <[email protected]>
+
+        Fix the semantics of passing contentsVisible flag to GraphicsLayers
+        https://bugs.webkit.org/show_bug.cgi?id=76975
+
+        Reviewed by Simon Fraser.
+
+        This patch is covered by existing tests, in particular
+        compositing/visibility/layer-visible-content.html; its
+        expectations are rebaselined.
+
+        * rendering/RenderLayerBacking.cpp:
+        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
+
 2012-01-25  Tony Chang  <[email protected]>
 
         support overflow:auto and overflow:scroll in new flexbox

Modified: trunk/Source/WebCore/rendering/RenderLayerBacking.cpp (105905 => 105906)


--- trunk/Source/WebCore/rendering/RenderLayerBacking.cpp	2012-01-25 19:43:06 UTC (rev 105905)
+++ trunk/Source/WebCore/rendering/RenderLayerBacking.cpp	2012-01-25 19:53:05 UTC (rev 105906)
@@ -403,7 +403,11 @@
 #endif
     
     m_owningLayer->updateVisibilityStatus();
-    m_graphicsLayer->setContentsVisible(m_owningLayer->hasVisibleContent());
+
+    // m_graphicsLayer is the corresponding GraphicsLayer for this RenderLayer and its non-compositing
+    // descendants. So, the visibility flag for m_graphicsLayer should be true if there are any
+    // non-compositing visible layers.
+    m_graphicsLayer->setContentsVisible(m_owningLayer->hasVisibleContent() || m_owningLayer->hasVisibleDescendant());
     
     RenderStyle* style = renderer()->style();
     m_graphicsLayer->setPreserves3D(style->transformStyle3D() == TransformStyle3DPreserve3D && !renderer()->hasReflection());
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to