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

Unified Diff: third_party/WebKit/Source/core/layout/LayoutBox.cpp

Issue 2716203003: Fix paint property under-invalidation of CSS clip on resize (Closed)
Patch Set: Created 3 years, 10 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/core/paint/PaintPropertyTreeUpdateTests.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/layout/LayoutBox.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutBox.cpp b/third_party/WebKit/Source/core/layout/LayoutBox.cpp
index 3d8e6aff6c568f4f62405a253c1bb7be86cca4a2..456e411cbfb3a0d7b3ddef0e74bf1e6bd0209937 100644
--- a/third_party/WebKit/Source/core/layout/LayoutBox.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutBox.cpp
@@ -1735,6 +1735,10 @@ void LayoutBox::sizeChanged() {
// overflowClipRect(). The border box rect's size equals the frame rect's
// size so we trigger a paint property update when the frame rect changes.
setNeedsPaintPropertyUpdate();
+ } else if (hasClip()) {
chrishtr 2017/02/28 00:11:18 Is this needed for clip-path as well?
Xianzhu 2017/02/28 00:17:20 We seem not to support clip-path in paint property
trchen 2017/02/28 00:43:28 Thanks for the heads up! Yea, I think this will be
+ // The used value of CSS clip may depend on size of the box, e.g. for
+ // clip: rect(auto auto auto -5px).
+ setNeedsPaintPropertyUpdate();
} else if (styleRef().hasTransform() || styleRef().hasPerspective()) {
// Relative lengths (e.g., percentage values) in transform, perspective,
// transform-origin, and perspective-origin can depend on the size of the
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/paint/PaintPropertyTreeUpdateTests.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698