Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(495)

Unified Diff: Source/core/rendering/RenderLayerCompositor.cpp

Issue 17398002: Add tests and settings plumbing for accelerated fixed root background (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/platform/graphics/GraphicsLayerClient.h ('k') | Source/core/testing/Internals.idl » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/RenderLayerCompositor.cpp
diff --git a/Source/core/rendering/RenderLayerCompositor.cpp b/Source/core/rendering/RenderLayerCompositor.cpp
index f472d127bcb8eb2dfaba789a65cf4fab397f1700..13587deb2282f33def84ae46d4dc1f3b1b8c9ec5 100644
--- a/Source/core/rendering/RenderLayerCompositor.cpp
+++ b/Source/core/rendering/RenderLayerCompositor.cpp
@@ -49,6 +49,7 @@
#include "core/platform/ScrollbarTheme.h"
#include "core/platform/chromium/TraceEvent.h"
#include "core/platform/graphics/GraphicsLayer.h"
+#include "core/platform/graphics/GraphicsLayerClient.h"
#include "core/platform/graphics/transforms/TransformState.h"
#include "core/rendering/HitTestResult.h"
#include "core/rendering/RenderApplet.h"
@@ -1212,8 +1213,13 @@ String RenderLayerCompositor::layerTreeAsText(LayerTreeFlags flags)
return String();
// We skip dumping the scroll and clip layers to keep layerTreeAsText output
- // similar between platforms.
- String layerTreeText = m_rootContentLayer->layerTreeAsText(flags);
+ // similar between platforms (unless we explicitly request dumping from the
enne (OOO) 2013/07/03 18:26:57 layerTreeAsText is so fragile. :(
+ // root.
+ GraphicsLayer* rootLayer = m_rootContentLayer.get();
+ if (flags & LayerTreeIncludesRootLayer)
+ rootLayer = rootGraphicsLayer();
+
+ String layerTreeText = rootLayer->layerTreeAsText(flags);
// The true root layer is not included in the dump, so if we want to report
// its repaint rects, they must be included here.
« no previous file with comments | « Source/core/platform/graphics/GraphicsLayerClient.h ('k') | Source/core/testing/Internals.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698