Title: [210433] trunk/Source/WebCore
Revision
210433
Author
[email protected]
Date
2017-01-05 20:09:49 -0800 (Thu, 05 Jan 2017)

Log Message

TextFragmentIterator::runWidth does not need typename CharacterType<> anymore.
https://bugs.webkit.org/show_bug.cgi?id=166751

Reviewed by Simon Fraser.

No change in functionality.

* rendering/SimpleLineLayoutTextFragmentIterator.cpp:
(WebCore::SimpleLineLayout::TextFragmentIterator::textWidth):
* rendering/SimpleLineLayoutTextFragmentIterator.h:

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (210432 => 210433)


--- trunk/Source/WebCore/ChangeLog	2017-01-06 03:45:16 UTC (rev 210432)
+++ trunk/Source/WebCore/ChangeLog	2017-01-06 04:09:49 UTC (rev 210433)
@@ -1,3 +1,16 @@
+2017-01-05  Zalan Bujtas  <[email protected]>
+
+        TextFragmentIterator::runWidth does not need typename CharacterType<> anymore.
+        https://bugs.webkit.org/show_bug.cgi?id=166751
+
+        Reviewed by Simon Fraser.
+
+        No change in functionality.
+
+        * rendering/SimpleLineLayoutTextFragmentIterator.cpp:
+        (WebCore::SimpleLineLayout::TextFragmentIterator::textWidth):
+        * rendering/SimpleLineLayoutTextFragmentIterator.h:
+
 2017-01-05  Ryosuke Niwa  <[email protected]>
 
         Finding text doesn't work across shadow boundary

Modified: trunk/Source/WebCore/rendering/SimpleLineLayoutTextFragmentIterator.cpp (210432 => 210433)


--- trunk/Source/WebCore/rendering/SimpleLineLayoutTextFragmentIterator.cpp	2017-01-06 03:45:16 UTC (rev 210432)
+++ trunk/Source/WebCore/rendering/SimpleLineLayoutTextFragmentIterator.cpp	2017-01-06 04:09:49 UTC (rev 210433)
@@ -153,7 +153,7 @@
         return 0;
     if (m_style.font.isFixedPitch() || (from == segment.start && to == segment.end))
         return downcast<RenderText>(segment.renderer).width(from - segment.start, to - from, m_style.font, xPosition, nullptr, nullptr);
-    return segment.text.is8Bit() ? runWidth<LChar>(segment, from, to, xPosition) : runWidth<UChar>(segment, from, to, xPosition);
+    return runWidth(segment, from, to, xPosition);
 }
 
 unsigned TextFragmentIterator::skipToNextPosition(PositionType positionType, unsigned startPosition, float& width, float xPosition, bool& overlappingFragment)
@@ -195,7 +195,6 @@
     return nextPosition;
 }
 
-template <typename CharacterType>
 float TextFragmentIterator::runWidth(const FlowContents::Segment& segment, unsigned startPosition, unsigned endPosition, float xPosition) const
 {
     ASSERT(m_style.font.size());

Modified: trunk/Source/WebCore/rendering/SimpleLineLayoutTextFragmentIterator.h (210432 => 210433)


--- trunk/Source/WebCore/rendering/SimpleLineLayoutTextFragmentIterator.h	2017-01-06 03:45:16 UTC (rev 210432)
+++ trunk/Source/WebCore/rendering/SimpleLineLayoutTextFragmentIterator.h	2017-01-06 04:09:49 UTC (rev 210433)
@@ -118,7 +118,7 @@
     bool isHardLineBreak(const FlowContents::Iterator& segment) const;
     template <typename CharacterType> unsigned nextBreakablePosition(const FlowContents::Segment&, unsigned startPosition);
     template <typename CharacterType> unsigned nextNonWhitespacePosition(const FlowContents::Segment&, unsigned startPosition);
-    template <typename CharacterType> float runWidth(const FlowContents::Segment&, unsigned startPosition, unsigned endPosition, float xPosition) const;
+    float runWidth(const FlowContents::Segment&, unsigned startPosition, unsigned endPosition, float xPosition) const;
 
     FlowContents m_flowContents;
     FlowContents::Iterator m_currentSegment;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to