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

Unified Diff: Source/platform/text/BidiResolver.h

Issue 853903002: Render string sequences of more than 64k characters. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fixed tests. Created 5 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: Source/platform/text/BidiResolver.h
diff --git a/Source/platform/text/BidiResolver.h b/Source/platform/text/BidiResolver.h
index 356f89488517ce6c997c074e375deb1df0867f32..9a9ae025947d17721fedcd568733984b91bea47f 100644
--- a/Source/platform/text/BidiResolver.h
+++ b/Source/platform/text/BidiResolver.h
@@ -336,8 +336,15 @@ void BidiResolver<Iterator, Run>::appendRun(BidiRunList<Run>& runs)
endOffset = m_endOfRunAtEndOfLine.offset();
}
- if (endOffset >= startOffset)
- runs.addRun(new Run(startOffset, endOffset + 1, context(), m_direction));
+ endOffset += 1;
eae 2015/01/15 20:07:07 I know you just moved this but a comment explainin
Daniel Bratell 2015/01/16 13:47:32 Done.
+ while (startOffset < endOffset) {
+ unsigned end = endOffset;
+ const int limit = USHRT_MAX; // Use a small number in Debug to keep the code well tested?
+ if (end - startOffset > limit)
+ end = startOffset + limit;
+ runs.addRun(new Run(startOffset, end, context(), m_direction));
+ startOffset = end;
+ }
m_eor.increment();
m_sor = m_eor;
« Source/core/rendering/InlineIterator.h ('K') | « Source/core/rendering/InlineIterator.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698