[webkit-changes] [WebKit/WebKit] 456666: EWordSide should be an enum class

Abrar Rahman Protyasha noreply at github.com
Thu Sep 21 19:35:56 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 456666ee4e2dc383d138624c83e922838341d510
      https://github.com/WebKit/WebKit/commit/456666ee4e2dc383d138624c83e922838341d510
  Author: Abrar Rahman Protyasha <a_protyasha at apple.com>
  Date:   2023-09-21 (Thu, 21 Sep 2023)

  Changed paths:
    M Source/WebCore/accessibility/AXObjectCache.cpp
    M Source/WebCore/accessibility/AXObjectCache.h
    M Source/WebCore/accessibility/AccessibilityObject.cpp
    M Source/WebCore/accessibility/atspi/AccessibilityObjectTextAtspi.cpp
    M Source/WebCore/editing/AlternativeTextController.cpp
    M Source/WebCore/editing/Editor.cpp
    M Source/WebCore/editing/TypingCommand.cpp
    M Source/WebCore/editing/VisibleSelection.cpp
    M Source/WebCore/editing/VisibleUnits.cpp
    M Source/WebCore/editing/VisibleUnits.h

  Log Message:
  -----------
  EWordSide should be an enum class
https://bugs.webkit.org/show_bug.cgi?id=261770
rdar://115743034

Reviewed by Michael Catanzaro.

This commit narrows down the underlying type of EWordSide and converts it
to an enum class for type safety.

* Source/WebCore/accessibility/AXObjectCache.cpp:
(WebCore::AXObjectCache::startCharacterOffsetOfWord):
(WebCore::AXObjectCache::endCharacterOffsetOfWord):
(WebCore::AXObjectCache::previousWordStartCharacterOffset):
(WebCore::AXObjectCache::nextWordEndCharacterOffset):
(WebCore::AXObjectCache::leftWordRange):
(WebCore::AXObjectCache::rightWordRange):
* Source/WebCore/accessibility/AXObjectCache.h:
* Source/WebCore/accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::positionOfLeftWord const):
(WebCore::AccessibilityObject::positionOfRightWord const):
* Source/WebCore/accessibility/atspi/AccessibilityObjectTextAtspi.cpp:
(WebCore::AccessibilityObjectAtspi::boundaryOffset const):
* Source/WebCore/editing/AlternativeTextController.cpp:
(WebCore::AlternativeTextController::applyPendingCorrection):
(WebCore::AlternativeTextController::timerFired):
(WebCore::AlternativeTextController::respondToChangedSelection):
* Source/WebCore/editing/Editor.cpp:
(WebCore::didApplyAutocorrection):
(WebCore::Editor::markMisspellingsAfterTypingToWord):
(WebCore::Editor::updateMarkersForWordsAffectedByEditing):
(WebCore::Editor::editorUIUpdateTimerFired):
* Source/WebCore/editing/TypingCommand.cpp:
(WebCore::TypingCommand::markMisspellingsAfterTyping):
* Source/WebCore/editing/VisibleSelection.cpp:
(WebCore::VisibleSelection::adjustSelectionRespectingGranularity):
* Source/WebCore/editing/VisibleUnits.cpp:
(WebCore::startOfWord):
(WebCore::endOfWord):
(WebCore::isStartOfWord):
(WebCore::atBoundaryOfGranularity):
(WebCore::withinTextUnitOfGranularity):
(WebCore::nextWordBoundaryInDirection):
(WebCore::enclosingTextUnitOfGranularity):
* Source/WebCore/editing/VisibleUnits.h:

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




More information about the webkit-changes mailing list