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

Unified Diff: Source/core/layout/LayoutObject.h

Issue 1011393003: [S.P.] Invalidate the document element for view background when needed (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fix rendererHasNoBoxEffect() and TestExpectations Created 5 years, 9 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 | « LayoutTests/fast/repaint/resources/window-resize-repaint.js ('k') | Source/core/layout/LayoutObject.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/layout/LayoutObject.h
diff --git a/Source/core/layout/LayoutObject.h b/Source/core/layout/LayoutObject.h
index e1e005e128e46c62f23b0e0cad87b38cdbe05910..2e4d5cff9556ff8b768aa19caa76affd5c1cf663 100644
--- a/Source/core/layout/LayoutObject.h
+++ b/Source/core/layout/LayoutObject.h
@@ -256,11 +256,18 @@ public:
#endif
// FIXME: This could be used when changing the size of a renderer without children to skip some invalidations.
- bool rendererHasNoBoxEffect() const
+ // FIXME: This is incorrect for document element. Remove this when we enable slimming paint.
+ bool rendererHasNoBoxEffectObsolete() const
{
return !style()->hasVisualOverflowingEffect() && !style()->hasBorder() && !style()->hasBackground();
}
Xianzhu 2015/03/18 22:44:19 Because the current code works well, I don't want
+ // Correct version of !rendererHasNoBoxEffectObsolete().
+ bool hasBoxEffect() const
+ {
+ return hasBoxDecorationBackground() || style()->hasVisualOverflowingEffect();
Xianzhu 2015/03/18 22:44:19 hasBoxDecorationBackground() correctly considers t
+ }
+
// Obtains the nearest enclosing block (including this block) that contributes a first-line style to our inline
// children.
virtual LayoutBlock* firstLineBlock() const;
« no previous file with comments | « LayoutTests/fast/repaint/resources/window-resize-repaint.js ('k') | Source/core/layout/LayoutObject.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698