[webkit-changes] [WebKit/WebKit] 435613: AX ITM: Not necessary to cache IsFocused in isolat...

AndresGonzalezApple noreply at github.com
Tue Sep 12 07:30:25 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 435613e4bde15fb3fece5ccd449b3a4e3b1107d8
      https://github.com/WebKit/WebKit/commit/435613e4bde15fb3fece5ccd449b3a4e3b1107d8
  Author: Andres Gonzalez <andresg_22 at apple.com>
  Date:   2023-09-12 (Tue, 12 Sep 2023)

  Changed paths:
    M Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.cpp
    M Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.h
    M Source/WebCore/accessibility/isolatedtree/AXIsolatedTree.cpp
    M Source/WebCore/accessibility/isolatedtree/AXIsolatedTree.h
    M Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm

  Log Message:
  -----------
  AX ITM: Not necessary to cache IsFocused in isolated objects.
https://bugs.webkit.org/show_bug.cgi?id=261428
<rdar://problem/115312448>

Reviewed by Tyler Wilcock.

Instead of caching this property and updating it, this patch changes the implementation of AXIsolatedObject::isFocused() to use the tree's focused object ID. This guaranties consistency between the methods isFocused() and focusedUIElement(), in the sense that isFocused() will return true if and only if the object is the unique focus returned by focusedUIElement().

* Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.cpp:
(WebCore::AXIsolatedObject::initializeProperties):
* Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.h:
* Source/WebCore/accessibility/isolatedtree/AXIsolatedTree.cpp:
(WebCore::AXIsolatedTree::focusedNodeID):
(WebCore::AXIsolatedTree::focusedNode):
(WebCore::AXIsolatedTree::setFocusedNodeID):
(WebCore::AXIsolatedTree::applyPendingChanges):
* Source/WebCore/accessibility/isolatedtree/AXIsolatedTree.h:
* Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
(-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
Minor style changes.

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




More information about the webkit-changes mailing list