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

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

Issue 1604783002: ALL-IN-ONE: Optimization to previousBoundary() and nextBoundary() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@progressive_accumulator
Patch Set: Created 4 years, 11 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/PlainTextRange.cpp
diff --git a/third_party/WebKit/Source/core/editing/PlainTextRange.cpp b/third_party/WebKit/Source/core/editing/PlainTextRange.cpp
index d0b7331c88f13c3fc93344b61a51b3799831046f..db0432c8a9c45d14ee158e6d7517e5b4d6acbbeb 100644
--- a/third_party/WebKit/Source/core/editing/PlainTextRange.cpp
+++ b/third_party/WebKit/Source/core/editing/PlainTextRange.cpp
@@ -107,7 +107,7 @@ EphemeralRange PlainTextRange::createRangeFor(const ContainerNode& scope, GetRan
// FIXME: This is a workaround for the fact that the end of a run
// is often at the wrong position for emitted '\n's or if the
// layoutObject of the current node is a replaced element.
- if (len == 1 && (it.text().characterAt(0) == '\n' || it.isInsideAtomicInlineElement())) {
+ if (len == 1 && (it.characterAt(0) == '\n' || it.isInsideAtomicInlineElement())) {
it.advance();
if (!it.atEnd()) {
textRunEndPosition = it.startPositionInCurrentContainer();

Powered by Google App Engine
This is Rietveld 408576698