Title: [95348] trunk/Source/WebCore
Revision
95348
Author
commit-qu...@webkit.org
Date
2011-09-16 18:14:47 -0700 (Fri, 16 Sep 2011)

Log Message

Re-named isRootLayer to isNonCompositedContent because
that is what the flag actually means.
https://bugs.webkit.org/show_bug.cgi?id=68214

Patch by Shawn Singh <shawnsi...@chromium.org> on 2011-09-16
Reviewed by James Robinson.

Code cleanup towards unit testing.

* platform/graphics/chromium/LayerChromium.cpp:
(WebCore::LayerChromium::LayerChromium):
(WebCore::LayerChromium::pushPropertiesTo):
* platform/graphics/chromium/LayerChromium.h:
(WebCore::LayerChromium::setIsNonCompositedContent):
(WebCore::LayerChromium::isNonCompositedContent):
* platform/graphics/chromium/NonCompositedContentHost.cpp:
(WebCore::NonCompositedContentHost::NonCompositedContentHost):
* platform/graphics/chromium/TiledLayerChromium.cpp:
(WebCore::TiledLayerChromium::setLayerTreeHost):
* platform/graphics/chromium/cc/CCLayerImpl.cpp:
(WebCore::CCLayerImpl::CCLayerImpl):
* platform/graphics/chromium/cc/CCLayerImpl.h:
(WebCore::CCLayerImpl::setIsNonCompositedContent):
(WebCore::CCLayerImpl::isNonCompositedContent):
* platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
(WebCore::CCTiledLayerImpl::draw):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (95347 => 95348)


--- trunk/Source/WebCore/ChangeLog	2011-09-17 01:12:48 UTC (rev 95347)
+++ trunk/Source/WebCore/ChangeLog	2011-09-17 01:14:47 UTC (rev 95348)
@@ -1,3 +1,31 @@
+2011-09-16  Shawn Singh  <shawnsi...@chromium.org>
+
+        Re-named isRootLayer to isNonCompositedContent because
+        that is what the flag actually means.
+        https://bugs.webkit.org/show_bug.cgi?id=68214
+
+        Reviewed by James Robinson.
+
+        Code cleanup towards unit testing.
+
+        * platform/graphics/chromium/LayerChromium.cpp:
+        (WebCore::LayerChromium::LayerChromium):
+        (WebCore::LayerChromium::pushPropertiesTo):
+        * platform/graphics/chromium/LayerChromium.h:
+        (WebCore::LayerChromium::setIsNonCompositedContent):
+        (WebCore::LayerChromium::isNonCompositedContent):
+        * platform/graphics/chromium/NonCompositedContentHost.cpp:
+        (WebCore::NonCompositedContentHost::NonCompositedContentHost):
+        * platform/graphics/chromium/TiledLayerChromium.cpp:
+        (WebCore::TiledLayerChromium::setLayerTreeHost):
+        * platform/graphics/chromium/cc/CCLayerImpl.cpp:
+        (WebCore::CCLayerImpl::CCLayerImpl):
+        * platform/graphics/chromium/cc/CCLayerImpl.h:
+        (WebCore::CCLayerImpl::setIsNonCompositedContent):
+        (WebCore::CCLayerImpl::isNonCompositedContent):
+        * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
+        (WebCore::CCTiledLayerImpl::draw):
+
 2011-09-16  Simon Fraser  <simon.fra...@apple.com>
 
         Make custom scrollbar theme for use in DRT, to reduce pixel diffs between platforms

Modified: trunk/Source/WebCore/platform/graphics/chromium/LayerChromium.cpp (95347 => 95348)


--- trunk/Source/WebCore/platform/graphics/chromium/LayerChromium.cpp	2011-09-17 01:12:48 UTC (rev 95347)
+++ trunk/Source/WebCore/platform/graphics/chromium/LayerChromium.cpp	2011-09-17 01:14:47 UTC (rev 95348)
@@ -75,7 +75,7 @@
     , m_needsDisplayOnBoundsChange(false)
     , m_doubleSided(true)
     , m_usesLayerScissor(false)
-    , m_isRootLayer(false)
+    , m_isNonCompositedContent(false)
     , m_replicaLayer(0)
     , m_drawOpacity(0)
     , m_targetRenderSurface(0)
@@ -304,7 +304,7 @@
     layer->setDebugBorderWidth(m_debugBorderWidth);
     layer->setDoubleSided(m_doubleSided);
     layer->setDrawsContent(drawsContent());
-    layer->setIsRootLayer(m_isRootLayer);
+    layer->setIsNonCompositedContent(m_isNonCompositedContent);
     layer->setMasksToBounds(m_masksToBounds);
     layer->setName(m_name);
     layer->setOpacity(m_opacity);

Modified: trunk/Source/WebCore/platform/graphics/chromium/LayerChromium.h (95347 => 95348)


--- trunk/Source/WebCore/platform/graphics/chromium/LayerChromium.h	2011-09-17 01:12:48 UTC (rev 95347)
+++ trunk/Source/WebCore/platform/graphics/chromium/LayerChromium.h	2011-09-17 01:14:47 UTC (rev 95348)
@@ -157,8 +157,8 @@
     void setUsesLayerScissor(bool usesLayerScissor) { m_usesLayerScissor = usesLayerScissor; }
     bool usesLayerScissor() const { return m_usesLayerScissor; }
 
-    void setIsRootLayer(bool isRootLayer) { m_isRootLayer = isRootLayer; }
-    bool isRootLayer() const { return m_isRootLayer; }
+    void setIsNonCompositedContent(bool isNonCompositedContent) { m_isNonCompositedContent = isNonCompositedContent; }
+    bool isNonCompositedContent() const { return m_isNonCompositedContent; }
 
     virtual void setLayerTreeHost(CCLayerTreeHost*);
 
@@ -274,7 +274,7 @@
     bool m_needsDisplayOnBoundsChange;
     bool m_doubleSided;
     bool m_usesLayerScissor;
-    bool m_isRootLayer;
+    bool m_isNonCompositedContent;
 
     TransformationMatrix m_transform;
     TransformationMatrix m_sublayerTransform;

Modified: trunk/Source/WebCore/platform/graphics/chromium/NonCompositedContentHost.cpp (95347 => 95348)


--- trunk/Source/WebCore/platform/graphics/chromium/NonCompositedContentHost.cpp	2011-09-17 01:12:48 UTC (rev 95347)
+++ trunk/Source/WebCore/platform/graphics/chromium/NonCompositedContentHost.cpp	2011-09-17 01:14:47 UTC (rev 95348)
@@ -42,7 +42,7 @@
     m_graphicsLayer->setName("non-composited content");
 #endif
     m_graphicsLayer->setDrawsContent(true);
-    m_graphicsLayer->platformLayer()->setIsRootLayer(true);
+    m_graphicsLayer->platformLayer()->setIsNonCompositedContent(true);
 }
 
 NonCompositedContentHost::~NonCompositedContentHost()

Modified: trunk/Source/WebCore/platform/graphics/chromium/TiledLayerChromium.cpp (95347 => 95348)


--- trunk/Source/WebCore/platform/graphics/chromium/TiledLayerChromium.cpp	2011-09-17 01:12:48 UTC (rev 95347)
+++ trunk/Source/WebCore/platform/graphics/chromium/TiledLayerChromium.cpp	2011-09-17 01:14:47 UTC (rev 95348)
@@ -148,7 +148,7 @@
     m_sampledTexelFormat = textureUpdater()->sampledTexelFormat(m_textureFormat);
     m_tiler = CCLayerTilingData::create(
         IntSize(defaultTileSize, defaultTileSize),
-        isRootLayer() ? CCLayerTilingData::NoBorderTexels : CCLayerTilingData::HasBorderTexels);
+        isNonCompositedContent() ? CCLayerTilingData::NoBorderTexels : CCLayerTilingData::HasBorderTexels);
 }
 
 void TiledLayerChromium::updateCompositorResources(GraphicsContext3D* context)

Modified: trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerImpl.cpp (95347 => 95348)


--- trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerImpl.cpp	2011-09-17 01:12:48 UTC (rev 95347)
+++ trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerImpl.cpp	2011-09-17 01:14:47 UTC (rev 95348)
@@ -47,7 +47,7 @@
     , m_opacity(1.0)
     , m_preserves3D(false)
     , m_usesLayerScissor(false)
-    , m_isRootLayer(false)
+    , m_isNonCompositedContent(false)
     , m_drawsContent(false)
     , m_targetRenderSurface(0)
     , m_drawDepth(0)

Modified: trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerImpl.h (95347 => 95348)


--- trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerImpl.h	2011-09-17 01:12:48 UTC (rev 95347)
+++ trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerImpl.h	2011-09-17 01:14:47 UTC (rev 95348)
@@ -104,8 +104,8 @@
     void setUsesLayerScissor(bool usesLayerScissor) { m_usesLayerScissor = usesLayerScissor; }
     bool usesLayerScissor() const { return m_usesLayerScissor; }
 
-    void setIsRootLayer(bool isRootLayer) { m_isRootLayer = isRootLayer; }
-    bool isRootLayer() const { return m_isRootLayer; }
+    void setIsNonCompositedContent(bool isNonCompositedContent) { m_isNonCompositedContent = isNonCompositedContent; }
+    bool isNonCompositedContent() const { return m_isNonCompositedContent; }
 
     void setSublayerTransform(const TransformationMatrix& sublayerTransform) { m_sublayerTransform = sublayerTransform; }
     const TransformationMatrix& sublayerTransform() const { return m_sublayerTransform; }
@@ -203,7 +203,7 @@
     TransformationMatrix m_sublayerTransform;
     TransformationMatrix m_transform;
     bool m_usesLayerScissor;
-    bool m_isRootLayer;
+    bool m_isNonCompositedContent;
 
     bool m_drawsContent;
 

Modified: trunk/Source/WebCore/platform/graphics/chromium/cc/CCTiledLayerImpl.cpp (95347 => 95348)


--- trunk/Source/WebCore/platform/graphics/chromium/cc/CCTiledLayerImpl.cpp	2011-09-17 01:12:48 UTC (rev 95347)
+++ trunk/Source/WebCore/platform/graphics/chromium/cc/CCTiledLayerImpl.cpp	2011-09-17 01:14:47 UTC (rev 95348)
@@ -120,7 +120,7 @@
         layerQuad.inflateAntiAliasingDistance();
 
     GraphicsContext3D* context = layerRenderer->context();
-    if (isRootLayer()) {
+    if (isNonCompositedContent()) {
         context->colorMask(true, true, true, false);
         GLC(context, context->disable(GraphicsContext3D::BLEND));
     }
@@ -148,7 +148,7 @@
         ASSERT_NOT_REACHED();
     }
 
-    if (isRootLayer()) {
+    if (isNonCompositedContent()) {
         context->colorMask(true, true, true, true);
         GLC(context, context->enable(GraphicsContext3D::BLEND));
     }
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to