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

Unified Diff: third_party/WebKit/Source/core/editing/VisibleSelection.cpp

Issue 1909343003: TextIteratorAlgorithm should not force layout update in constructor. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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/VisibleSelection.cpp
diff --git a/third_party/WebKit/Source/core/editing/VisibleSelection.cpp b/third_party/WebKit/Source/core/editing/VisibleSelection.cpp
index a63e17b8fcaa4840b906c5934670f7c35c8b746e..4636b51ca279bced01f675cfab460ba2ab0074da 100644
--- a/third_party/WebKit/Source/core/editing/VisibleSelection.cpp
+++ b/third_party/WebKit/Source/core/editing/VisibleSelection.cpp
@@ -290,6 +290,10 @@ void VisibleSelectionTemplate<Strategy>::appendTrailingWhitespace()
if (searchRange.isNull())
return;
+ // TODO(dglazkov): The use of updateLayoutIgnorePendingStylesheets needs to be audited.
+ // see http://crbug.com/590369 for more details.
+ searchRange.startPosition().document()->updateLayoutIgnorePendingStylesheets();
+
CharacterIteratorAlgorithm<Strategy> charIt(searchRange.startPosition(), searchRange.endPosition(), TextIteratorEmitsCharactersBetweenAllVisiblePositions);
bool changed = false;
« no previous file with comments | « third_party/WebKit/Source/core/editing/PlainTextRange.cpp ('k') | third_party/WebKit/Source/core/editing/VisibleUnits.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698