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

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

Issue 2240753003: Fix column rule under invalidation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: - Created 4 years, 4 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 | « third_party/WebKit/LayoutTests/paint/invalidation/column-rule-change-expected.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/paint/BlockFlowPaintInvalidator.cpp
diff --git a/third_party/WebKit/Source/core/paint/BlockFlowPaintInvalidator.cpp b/third_party/WebKit/Source/core/paint/BlockFlowPaintInvalidator.cpp
index b70c1f566968085122d73d5d3d6684cd6fcc6ffc..728573389951f2a0999f7dc4ebd528e239239cdd 100644
--- a/third_party/WebKit/Source/core/paint/BlockFlowPaintInvalidator.cpp
+++ b/third_party/WebKit/Source/core/paint/BlockFlowPaintInvalidator.cpp
@@ -14,6 +14,8 @@ PaintInvalidationReason BlockFlowPaintInvalidator::invalidatePaintIfNeeded()
{
PaintInvalidationReason reason = BoxPaintInvalidator(m_blockFlow, m_context).invalidatePaintIfNeeded();
+ // TODO(wangxianzhu): Refactor the following into invalidateDisplayItemClients().
+
if (reason == PaintInvalidationNone || reason == PaintInvalidationDelayedFull)
return reason;
@@ -24,6 +26,16 @@ PaintInvalidationReason BlockFlowPaintInvalidator::invalidatePaintIfNeeded()
// we just invalidate it unconditionally which is typically cheaper.
m_blockFlow.invalidateDisplayItemClient(*line, reason);
}
+
+ if (m_blockFlow.multiColumnFlowThread()) {
+ // Invalidate child LayoutMultiColumnSets which may need to repaint column rules after
+ // m_blockFlow's column rule style and/or layout changed.
+ for (LayoutObject* child = m_blockFlow.firstChild(); child; child = child->nextSibling()) {
+ if (child->isLayoutMultiColumnSet() && !child->shouldDoFullPaintInvalidation())
+ m_blockFlow.invalidateDisplayItemClient(*child, reason);
+ }
+ }
+
return reason;
}
« no previous file with comments | « third_party/WebKit/LayoutTests/paint/invalidation/column-rule-change-expected.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698