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

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

Issue 1473363003: Invalidate first line display item clients when first line style changes (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Separate block and line code Created 5 years 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/layout/LayoutBlockFlow.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutBlockFlow.cpp b/third_party/WebKit/Source/core/layout/LayoutBlockFlow.cpp
index 543857208a025c1c921b647e7c1722bc47083e21..5c2e2c3bf883d9b064a282e50e539d3be3928dd2 100644
--- a/third_party/WebKit/Source/core/layout/LayoutBlockFlow.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutBlockFlow.cpp
@@ -3112,4 +3112,20 @@ void LayoutBlockFlow::positionDialog()
dialog->setCentered(top);
}
+static void invalidateDisplayItemClientsOfInlineBoxRecursively(InlineBox& box)
mstensho (USE GERRIT) 2015/12/03 12:08:10 All of this should go into LayoutBlockFlowLine.cpp
Xianzhu 2015/12/03 17:38:22 Done.
+{
+ box.layoutObject().invalidateDisplayItemClient(box);
+ if (!box.isInlineFlowBox())
+ return;
+ for (InlineBox* child = toInlineFlowBox(box).firstChild(); child; child = child->nextOnLine())
mstensho (USE GERRIT) 2015/12/03 12:08:10 @eae: can you comment on this, please? I don't kno
+ invalidateDisplayItemClientsOfInlineBoxRecursively(*child);
+}
+
+void LayoutBlockFlow::invalidateDisplayItemClientsOfFirstLine()
+{
+ ASSERT(childrenInline());
+ if (RootInlineBox* firstRootBox = this->firstRootBox())
+ invalidateDisplayItemClientsOfInlineBoxRecursively(*firstRootBox);
+}
+
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698