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

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

Issue 2194273002: Fix border radius on composited children. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Improve clip recording code Created 4 years, 1 month 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
Index: third_party/WebKit/Source/core/paint/PaintLayer.cpp
diff --git a/third_party/WebKit/Source/core/paint/PaintLayer.cpp b/third_party/WebKit/Source/core/paint/PaintLayer.cpp
index f782b1f5fccd6c254b4cc187356ca2afcaa1efb1..e84caa5cab607278c09748cee4a8cced2921af22 100644
--- a/third_party/WebKit/Source/core/paint/PaintLayer.cpp
+++ b/third_party/WebKit/Source/core/paint/PaintLayer.cpp
@@ -1565,6 +1565,7 @@ void PaintLayer::appendSingleFragmentIgnoringPagination(
ClipRectsCacheSlot clipRectsCacheSlot,
OverlayScrollbarClipBehavior overlayScrollbarClipBehavior,
ShouldRespectOverflowClipType respectOverflowClip,
+ bool paintingAncestorClippingMask,
const LayoutPoint* offsetFromRoot,
const LayoutSize& subPixelAccumulation) {
PaintLayerFragment fragment;
@@ -1575,7 +1576,7 @@ void PaintLayer::appendSingleFragmentIgnoringPagination(
clipRectsContext.setIgnoreOverflowClip();
clipper().calculateRects(clipRectsContext, dirtyRect, fragment.layerBounds,
fragment.backgroundRect, fragment.foregroundRect,
- offsetFromRoot);
+ offsetFromRoot, paintingAncestorClippingMask);
Stephen Chennney 2016/11/08 21:42:51 Here we can create a clipper (PaintLayerClipper) w
fragments.append(fragment);
}
@@ -1593,6 +1594,7 @@ void PaintLayer::collectFragments(
ClipRectsCacheSlot clipRectsCacheSlot,
OverlayScrollbarClipBehavior overlayScrollbarClipBehavior,
ShouldRespectOverflowClipType respectOverflowClip,
+ bool paintingAncestorClippingMask,
const LayoutPoint* offsetFromRoot,
const LayoutSize& subPixelAccumulation,
const LayoutRect* layerBoundingBox) {
@@ -1600,16 +1602,16 @@ void PaintLayer::collectFragments(
// For unpaginated layers, there is only one fragment.
appendSingleFragmentIgnoringPagination(
fragments, rootLayer, dirtyRect, clipRectsCacheSlot,
- overlayScrollbarClipBehavior, respectOverflowClip, offsetFromRoot,
- subPixelAccumulation);
+ overlayScrollbarClipBehavior, respectOverflowClip,
+ paintingAncestorClippingMask, offsetFromRoot, subPixelAccumulation);
return;
}
if (!shouldFragmentCompositedBounds(rootLayer)) {
appendSingleFragmentIgnoringPagination(
fragments, rootLayer, dirtyRect, clipRectsCacheSlot,
- overlayScrollbarClipBehavior, respectOverflowClip, offsetFromRoot,
- subPixelAccumulation);
+ overlayScrollbarClipBehavior, respectOverflowClip,
+ paintingAncestorClippingMask, offsetFromRoot, subPixelAccumulation);
return;
}
@@ -1632,7 +1634,8 @@ void PaintLayer::collectFragments(
clipper().calculateRects(
paginationClipRectsContext, LayoutRect(LayoutRect::infiniteIntRect()),
layerBoundsInFlowThread, backgroundRectInFlowThread,
- foregroundRectInFlowThread, &offsetWithinPaginatedLayer);
+ foregroundRectInFlowThread, &offsetWithinPaginatedLayer,
+ paintingAncestorClippingMask);
// Take our bounding box within the flow thread and clip it.
LayoutRect layerBoundingBoxInFlowThread =
@@ -2163,7 +2166,7 @@ PaintLayer* PaintLayer::hitTestTransformedLayerInFragments(
PaintLayer::RootOfTransparencyClipBox, LayoutSize());
enclosingPaginationLayer()->collectFragments(
enclosingPaginationFragments, rootLayer, hitTestRect, clipRectsCacheSlot,
- ExcludeOverlayScrollbarSizeForHitTesting, RespectOverflowClip,
+ ExcludeOverlayScrollbarSizeForHitTesting, RespectOverflowClip, false,
&offsetOfPaginationLayerFromRoot, LayoutSize(), &transformedExtent);
for (int i = enclosingPaginationFragments.size() - 1; i >= 0; --i) {

Powered by Google App Engine
This is Rietveld 408576698