[webkit-changes] [WebKit/WebKit] af7823: AX: Don't cache AXPropertyName::{FocusableAncestor...

Tyler Wilcock noreply at github.com
Sat Dec 24 18:23:41 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: af7823b64640a6e3415aed5ce522877b54b004b3
      https://github.com/WebKit/WebKit/commit/af7823b64640a6e3415aed5ce522877b54b004b3
  Author: Tyler Wilcock <tyler_w at apple.com>
  Date:   2022-12-24 (Sat, 24 Dec 2022)

  Changed paths:
    A LayoutTests/accessibility/editable-ancestor-expected.txt
    A LayoutTests/accessibility/editable-ancestor.html
    A LayoutTests/accessibility/focusable-ancestor-expected.txt
    A LayoutTests/accessibility/focusable-ancestor.html
    R LayoutTests/accessibility/mac/ancestor-attributes-expected.txt
    R LayoutTests/accessibility/mac/ancestor-attributes.html
    M LayoutTests/platform/glib/TestExpectations
    M LayoutTests/platform/mac-wk1/TestExpectations
    M LayoutTests/platform/win/TestExpectations
    M Source/WebCore/accessibility/AccessibilityObject.cpp
    M Source/WebCore/accessibility/AccessibilityObject.h
    M Source/WebCore/accessibility/AccessibilityObjectInterface.h
    M Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.cpp
    M Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.h
    M Source/WebCore/accessibility/isolatedtree/AXIsolatedTree.h
    M Tools/WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h
    M Tools/WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl
    M Tools/WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm

  Log Message:
  -----------
  AX: Don't cache AXPropertyName::{FocusableAncestor, EditableAncestor, HighestEditableAncestor}
https://bugs.webkit.org/show_bug.cgi?id=249853
rdar://problem/103675565

Reviewed by Chris Fleizach.

With this patch, these properties are removed:

  - AXPropertyName::FocusableAncestor
  - AXPropertyName::EditableAncestor
  - AXPropertyName::HighestEditableAncestor

These properties could get stale after dynamic page changes, and there's
no great way to update them cheaply. With this patch, we now resolve these
properties on-demand. This is better for several reasons:

  1. They cannot be stale
  2. Lowers upfront cost of creating isolated tree node, which can
     greatly hurt performance on some sites
  3. Lowers memory usage

* LayoutTests/accessibility/mac/ancestor-attributes-expected.txt:
* LayoutTests/accessibility/mac/ancestor-attributes.html:
Delete this test. It's replaced by the two more modern-style tests below.
* LayoutTests/accessibility/editable-ancestor-expected.txt: Added.
* LayoutTests/accessibility/editable-ancestor.html: Added.
* LayoutTests/accessibility/focusable-ancestor-expected.txt: Added.
* LayoutTests/accessibility/focusable-ancestor.html: Added.

* LayoutTests/platform/glib/TestExpectations:
* LayoutTests/platform/mac-wk1/TestExpectations:
* LayoutTests/platform/win/TestExpectations:
Skip new tests.

* Source/WebCore/accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::focusableAncestor): Deleted.
(WebCore::AccessibilityObject::editableAncestor): Deleted.
(WebCore::AccessibilityObject::highestEditableAncestor): Deleted.
* Source/WebCore/accessibility/AccessibilityObject.h:
* Source/WebCore/accessibility/AccessibilityObjectInterface.h:
(WebCore::Accessibility::focusableAncestor):
(WebCore::Accessibility::editableAncestor):
(WebCore::Accessibility::highestEditableAncestor):
* Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.cpp:
(WebCore::AXIsolatedObject::initializeProperties):
(WebCore::AXIsolatedObject::parentObjectUnignored const):
* Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.h:
* Source/WebCore/accessibility/isolatedtree/AXIsolatedTree.h:
* Tools/WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h:
(WTR::AccessibilityUIElement::focusableAncestor):
(WTR::AccessibilityUIElement::editableAncestor):
(WTR::AccessibilityUIElement::highestEditableAncestor):
* Tools/WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl:
* Tools/WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm:
(WTR::AccessibilityUIElement::focusableAncestor):
(WTR::AccessibilityUIElement::editableAncestor):
(WTR::AccessibilityUIElement::highestEditableAncestor):

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




More information about the webkit-changes mailing list