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

Unified Diff: third_party/WebKit/Source/core/editing/commands/InsertListCommand.cpp

Issue 2413633002: Prune createVisiblePositionDeprecated from EditingUtilities (Closed)
Patch Set: Created 4 years, 2 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
Index: third_party/WebKit/Source/core/editing/commands/InsertListCommand.cpp
diff --git a/third_party/WebKit/Source/core/editing/commands/InsertListCommand.cpp b/third_party/WebKit/Source/core/editing/commands/InsertListCommand.cpp
index 039777856d1be5fd214f58712ed40f8c55afe50e..3e407fe0f933d310ca1cdcf9097bdfbf48ed6820 100644
--- a/third_party/WebKit/Source/core/editing/commands/InsertListCommand.cpp
+++ b/third_party/WebKit/Source/core/editing/commands/InsertListCommand.cpp
@@ -68,12 +68,15 @@ HTMLUListElement* InsertListCommand::fixOrphanedListChild(
HTMLElement* InsertListCommand::mergeWithNeighboringLists(
HTMLElement* passedList,
EditingState* editingState) {
+ document().updateStyleAndLayoutIgnorePendingStylesheets();
yosin_UTC9 2016/10/12 07:32:00 It is better to call updateSAL() just before |canM
Xiaocheng 2016/10/12 07:45:56 Done.
+
HTMLElement* list = passedList;
Element* previousList = ElementTraversal::previousSibling(*list);
if (canMergeLists(previousList, list)) {
mergeIdenticalElements(previousList, list, editingState);
if (editingState->isAborted())
return nullptr;
+ document().updateStyleAndLayoutIgnorePendingStylesheets();
yosin_UTC9 2016/10/12 07:32:00 Please move this updateSAL() just before |canMerge
Xiaocheng 2016/10/12 07:45:57 Done.
}
if (!list)
@@ -530,6 +533,7 @@ void InsertListCommand::listifyParagraph(const VisiblePosition& originalStart,
if (editingState->isAborted())
return;
+ document().updateStyleAndLayoutIgnorePendingStylesheets();
if (canMergeLists(previousList, nextList))
mergeIdenticalElements(previousList, nextList, editingState);

Powered by Google App Engine
This is Rietveld 408576698