[webkit-changes] [WebKit/WebKit] 4d176c: Remove unnecessary LineBreakIteratorMode type alias

Myles C. Maxfield noreply at github.com
Mon Jun 12 00:10:03 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 4d176cd7aa8d8788a84761c8d8ca4091d90d9c3f
      https://github.com/WebKit/WebKit/commit/4d176cd7aa8d8788a84761c8d8ca4091d90d9c3f
  Author: Myles C. Maxfield <mmaxfield at apple.com>
  Date:   2023-06-12 (Mon, 12 Jun 2023)

  Changed paths:
    M Source/WTF/wtf/text/TextBreakIterator.h
    M Source/WebCore/layout/formattingContexts/inline/text/TextUtil.cpp
    M Source/WebCore/layout/formattingContexts/inline/text/TextUtil.h
    M Source/WebCore/rendering/RenderText.cpp
    M Source/WebCore/rendering/RenderText.h
    M Source/WebCore/rendering/line/BreakingContext.h

  Log Message:
  -----------
  Remove unnecessary LineBreakIteratorMode type alias
https://bugs.webkit.org/show_bug.cgi?id=257946
rdar://110622665

Reviewed by Tim Nguyen.

TextBreakIterator::LineMode::Behavior is the type we use throughout the
line breaking code, so it doesn't really make sense for there to be 2
names for the same thing. LineBreakIteratorMode is left over from the
LazyLineBreakIterator refactor.

* Source/WTF/wtf/text/TextBreakIterator.h:
(WTF::CachedLineBreakIteratorFactory::CachedLineBreakIteratorFactory):
(WTF::CachedLineBreakIteratorFactory::mode const):
(WTF::CachedLineBreakIteratorFactory::resetStringAndReleaseIterator):
* Source/WebCore/layout/formattingContexts/inline/text/TextUtil.cpp:
(WebCore::Layout::TextUtil::findNextBreakablePosition):
(WebCore::Layout::TextUtil::TextBreakIterator::LineMode::Behavior):
(WebCore::Layout::TextUtil::lineBreakIteratorMode): Deleted.
* Source/WebCore/layout/formattingContexts/inline/text/TextUtil.h:
* Source/WebCore/rendering/RenderText.cpp:
(WebCore::mapLineBreakToIteratorMode):
(WebCore::RenderText::computePreferredLogicalWidths):
* Source/WebCore/rendering/RenderText.h:
* Source/WebCore/rendering/line/BreakingContext.h:
(WebCore::BreakingContext::handleText):

Canonical link: https://commits.webkit.org/265061@main




More information about the webkit-changes mailing list