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

Unified Diff: third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp

Issue 2364233002: Switch the Root Layer Scrolls codepath to use root clip paint properties (Closed)
Patch Set: Created 4 years, 3 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 | « no previous file | third_party/WebKit/Source/platform/graphics/paint/ClipPaintPropertyNode.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp
diff --git a/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp b/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp
index e865b4025c9ebe78df5878752cef66db106e8c0b..669e7c1553be867de3774da5748084f3189f824a 100644
--- a/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp
+++ b/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp
@@ -50,13 +50,14 @@ PaintPropertyTreeBuilderContext PaintPropertyTreeBuilder::setupInitialContext()
{
PaintPropertyTreeBuilderContext context;
- // TODO(pdr): Update the root layer scrolling paths to use the static root nodes.
+ context.current.clip = context.absolutePosition.clip = context.fixedPosition.clip = rootClipNode();
+
+ // TODO(pdr): Update the root layer scrolling paths to use the static root nodes for transform, effect, and scroll.
if (RuntimeEnabledFeatures::rootLayerScrollingEnabled())
return context;
context.current.transform = context.absolutePosition.transform = context.fixedPosition.transform = rootTransformNode();
context.current.scroll = context.absolutePosition.scroll = context.fixedPosition.scroll = rootScrollNode();
- context.current.clip = context.absolutePosition.clip = context.fixedPosition.clip = rootClipNode();
context.currentEffect = rootEffectNode();
// Ensure scroll tree properties are reset. They will be rebuilt during the tree walk.
@@ -326,14 +327,6 @@ void PaintPropertyTreeBuilder::updateLocalBorderBoxContext(const LayoutObject& o
borderBoxContext->geometryPropertyTreeState = GeometryPropertyTreeState(context.current.transform, context.current.clip, context.currentEffect);
borderBoxContext->scroll = context.current.scroll;
- if (!context.current.clip) {
- DCHECK(object.isLayoutView());
- DCHECK(toLayoutView(object).frameView()->frame().isMainFrame());
- DCHECK(RuntimeEnabledFeatures::rootLayerScrollingEnabled());
- borderBoxContext->geometryPropertyTreeState.clip = ClipPaintPropertyNode::create(nullptr, context.current.transform, FloatRoundedRect(LayoutRect::infiniteIntRect()));
- context.current.clip = borderBoxContext->geometryPropertyTreeState.clip.get();
- }
-
object.getMutableForPainting().ensureObjectPaintProperties().setLocalBorderBoxProperties(std::move(borderBoxContext));
}
« no previous file with comments | « no previous file | third_party/WebKit/Source/platform/graphics/paint/ClipPaintPropertyNode.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698