Title: [257841] trunk/Source/WebCore
- Revision
- 257841
- Author
- za...@apple.com
- Date
- 2020-03-04 07:19:14 -0800 (Wed, 04 Mar 2020)
Log Message
[LFC][IFC] Display::Run::TextContent::expand(unsigned) is called with the value of -1.
https://bugs.webkit.org/show_bug.cgi?id=208558
<rdar://problem/60026658>
Reviewed by Antti Koivisto.
* layout/displaytree/DisplayRun.h:
(WebCore::Display::Run::TextContent::shrink):
* layout/inlineformatting/InlineLineBuilder.cpp:
(WebCore::Layout::LineBuilder::Run::removeTrailingWhitespace):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (257840 => 257841)
--- trunk/Source/WebCore/ChangeLog 2020-03-04 14:53:01 UTC (rev 257840)
+++ trunk/Source/WebCore/ChangeLog 2020-03-04 15:19:14 UTC (rev 257841)
@@ -1,5 +1,18 @@
2020-03-04 Zalan Bujtas <za...@apple.com>
+ [LFC][IFC] Display::Run::TextContent::expand(unsigned) is called with the value of -1.
+ https://bugs.webkit.org/show_bug.cgi?id=208558
+ <rdar://problem/60026658>
+
+ Reviewed by Antti Koivisto.
+
+ * layout/displaytree/DisplayRun.h:
+ (WebCore::Display::Run::TextContent::shrink):
+ * layout/inlineformatting/InlineLineBuilder.cpp:
+ (WebCore::Layout::LineBuilder::Run::removeTrailingWhitespace):
+
+2020-03-04 Zalan Bujtas <za...@apple.com>
+
[First paint] Going from visually empty to non-empty should immediately trigger layer unfreezing
https://bugs.webkit.org/show_bug.cgi?id=208385
<rdar://problem/59895900>
Modified: trunk/Source/WebCore/layout/displaytree/DisplayRun.h (257840 => 257841)
--- trunk/Source/WebCore/layout/displaytree/DisplayRun.h 2020-03-04 14:53:01 UTC (rev 257840)
+++ trunk/Source/WebCore/layout/displaytree/DisplayRun.h 2020-03-04 15:19:14 UTC (rev 257841)
@@ -54,6 +54,7 @@
void setNeedsHyphen() { m_needsHyphen = true; }
void expand(unsigned delta) { m_length += delta; }
+ void shrink(unsigned delta) { m_length -= delta; }
private:
unsigned m_start { 0 };
Modified: trunk/Source/WebCore/layout/inlineformatting/InlineLineBuilder.cpp (257840 => 257841)
--- trunk/Source/WebCore/layout/inlineformatting/InlineLineBuilder.cpp 2020-03-04 14:53:01 UTC (rev 257840)
+++ trunk/Source/WebCore/layout/inlineformatting/InlineLineBuilder.cpp 2020-03-04 15:19:14 UTC (rev 257841)
@@ -833,7 +833,8 @@
// According to https://www.w3.org/TR/css-text-3/#white-space-property matrix
// Trimmable whitespace is always collapsable so the length of the trailing trimmable whitespace is always 1 (or non-existent).
ASSERT(m_textContent->length());
- m_textContent->expand(-1);
+ constexpr size_t trailingTrimmableContentLength = 1;
+ m_textContent->shrink(trailingTrimmableContentLength);
visuallyCollapseTrailingWhitespace();
}
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes