Implementation of additional attribute caching in the IsolatedTree.
authorandresg_22@apple.com <andresg_22@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 7 Dec 2019 20:34:35 +0000 (20:34 +0000)
committerandresg_22@apple.com <andresg_22@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 7 Dec 2019 20:34:35 +0000 (20:34 +0000)
https://bugs.webkit.org/show_bug.cgi?id=204918

Reviewed by Chris Fleizach.

Source/WebCore:

No new tests, no new functionality. Updated several tests to fixed
expected output.

- Implementation of around 200 methods in the AXIsolatedObject class.
- The pending method implementations have an ASSERT_NOT_REACHED.
- Support for dispatching to the main thread some
WebAccessibilityObjectWrapper methods that cannot be run in the
secondary thread.

* accessibility/AXObjectCache.cpp:
(WebCore::AXObjectCache::createIsolatedTreeHierarchy):
(WebCore::AXObjectCache::generateIsolatedTree):
* accessibility/AXObjectCache.h:
* accessibility/AccessibilityNodeObject.cpp:
(WebCore::AccessibilityNodeObject::ariaLabeledByText const):
* accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::actionVerb const):
(WebCore::AccessibilityObject::datetimeAttributeValue const):
(WebCore::AccessibilityObject::linkRelValue const):
(WebCore::AccessibilityObject::isInlineText const):
(WebCore::AccessibilityObject::identifierAttribute const):
(WebCore::AccessibilityObject::documentURI const):
(WebCore::AccessibilityObject::documentEncoding const):
(WebCore::AccessibilityObject::sessionID const):
(WebCore::AccessibilityObject::tagName const):
* accessibility/AccessibilityObject.h:
(WebCore::AccessibilityText::AccessibilityText):
(WebCore::AccessibilityObject::actionVerb const):
* accessibility/AccessibilityObjectInterface.h: Base implementation for
several isXXX methods that rely on the object roleValue.
(WebCore::AXCoreObject::isImageMap const):
(WebCore::AXCoreObject::isWebArea const):
(WebCore::AXCoreObject::isCheckbox const):
(WebCore::AXCoreObject::isRadioButton const):
(WebCore::AXCoreObject::isListBox const):
(WebCore::AXCoreObject::isSpinButton const):
(WebCore::AXCoreObject::isSwitch const):
(WebCore::AXCoreObject::isToggleButton const):
(WebCore::AXCoreObject::isTabList const):
(WebCore::AXCoreObject::isTabItem const):
(WebCore::AXCoreObject::isRadioGroup const):
(WebCore::AXCoreObject::isComboBox const):
(WebCore::AXCoreObject::isTree const):
(WebCore::AXCoreObject::isTreeGrid const):
(WebCore::AXCoreObject::isTreeItem const):
(WebCore::AXCoreObject::isScrollbar const):
(WebCore::AXCoreObject::isListItem const):
(WebCore::AXCoreObject::isCheckboxOrRadio const):
(WebCore::AXCoreObject::isScrollView const):
(WebCore::AXCoreObject::isCanvas const):
(WebCore::AXCoreObject::isPopUpButton const):
(WebCore::AXCoreObject::isColorWell const):
(WebCore::AXCoreObject::isSplitter const):
(WebCore::AXCoreObject::isToolbar const):
(WebCore::AXCoreObject::isSummary const):
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::accessKey const):
(WebCore::AccessibilityRenderObject::actionVerb const):
* accessibility/AccessibilityRenderObject.h:
* accessibility/AccessibilitySpinButton.h:
* accessibility/isolatedtree/AXIsolatedTree.cpp:
(WebCore::AXIsolatedTree::setRootNode):
(WebCore::AXIsolatedTree::setRoot): Renamed setRootNode.
* accessibility/isolatedtree/AXIsolatedTree.h:
* accessibility/isolatedtree/AXIsolatedTreeNode.cpp: Implementation of
around 200 methods in the AXIsolatedObject class. The methods that are
pending, have a stub implemetation with an ASSERT_NOT_REACHED.
(WebCore::AXIsolatedObject::AXIsolatedObject):
(WebCore::AXIsolatedObject::create):
(WebCore::AXIsolatedObject::initializeAttributeData):
(WebCore::AXIsolatedObject::setMathscripts):
(WebCore::AXIsolatedObject::setObjectVectorProperty):
(WebCore::AXIsolatedObject::isDetached const):
(WebCore::AXIsolatedObject::isDetachedFromParent):
(WebCore::AXIsolatedObject::accessibilityText const):
(WebCore::AXIsolatedObject::classList const):
(WebCore::AXIsolatedObject::sessionID const):
(WebCore::AXIsolatedObject::documentURI const):
(WebCore::AXIsolatedObject::preventKeyboardDOMEventDispatch const):
(WebCore::AXIsolatedObject::documentEncoding const):
(WebCore::AXIsolatedObject::insertMathPairs):
(WebCore::AXIsolatedObject::mathPrescripts):
(WebCore::AXIsolatedObject::mathPostscripts):
(WebCore::AXIsolatedObject::scrollBar):
(WebCore::AXIsolatedObject::colorValue const):
(WebCore::AXIsolatedObject::intPointAttributeValue const):
(WebCore::AXIsolatedObject::vectorAttributeValue const):
(WebCore::AXIsolatedObject::optionSetAttributeValue const):
(WebCore::AXIsolatedObject::uint64AttributeValue const):
(WebCore::AXIsolatedObject::urlAttributeValue const):
(WebCore::AXIsolatedObject::colorAttributeValue const):
(WebCore::AXIsolatedObject::floatAttributeValue const):
(WebCore::AXIsolatedObject::fillChildrenVectorForProperty const):
(WebCore::AXIsolatedObject::replaceTextInRange):
(WebCore::AXIsolatedObject::insertText):
(WebCore::AXIsolatedObject::press):
(WebCore::AXIsolatedObject::performDefaultAction):
(WebCore::AXIsolatedObject::isAccessibilityObject const):
(WebCore::AXIsolatedObject::isAccessibilityNodeObject const):
(WebCore::AXIsolatedObject::isAccessibilityRenderObject const):
(WebCore::AXIsolatedObject::isAccessibilityScrollbar const):
(WebCore::AXIsolatedObject::isAccessibilityScrollView const):
(WebCore::AXIsolatedObject::isAccessibilitySVGRoot const):
(WebCore::AXIsolatedObject::isAccessibilitySVGElement const):
(WebCore::AXIsolatedObject::containsText const):
(WebCore::AXIsolatedObject::isAttachmentElement const):
(WebCore::AXIsolatedObject::isNativeImage const):
(WebCore::AXIsolatedObject::isImageButton const):
(WebCore::AXIsolatedObject::isContainedByPasswordField const):
(WebCore::AXIsolatedObject::passwordFieldOrContainingPasswordField):
(WebCore::AXIsolatedObject::isNativeTextControl const):
(WebCore::AXIsolatedObject::isNativeListBox const):
(WebCore::AXIsolatedObject::isListBoxOption const):
(WebCore::AXIsolatedObject::isSliderThumb const):
(WebCore::AXIsolatedObject::isInputSlider const):
(WebCore::AXIsolatedObject::isLabel const):
(WebCore::AXIsolatedObject::isDataTable const):
(WebCore::AXIsolatedObject::isImageMapLink const):
(WebCore::AXIsolatedObject::isNativeSpinButton const):
(WebCore::AXIsolatedObject::isSpinButtonPart const):
(WebCore::AXIsolatedObject::isMockObject const):
(WebCore::AXIsolatedObject::isMediaObject const):
(WebCore::AXIsolatedObject::isARIATextControl const):
(WebCore::AXIsolatedObject::isNonNativeTextControl const):
(WebCore::AXIsolatedObject::isBlockquote const):
(WebCore::AXIsolatedObject::isLandmark const):
(WebCore::AXIsolatedObject::isFigureElement const):
(WebCore::AXIsolatedObject::isKeyboardFocusable const):
(WebCore::AXIsolatedObject::isHovered const):
(WebCore::AXIsolatedObject::isIndeterminate const):
(WebCore::AXIsolatedObject::isLoaded const):
(WebCore::AXIsolatedObject::isOnScreen const):
(WebCore::AXIsolatedObject::isOffScreen const):
(WebCore::AXIsolatedObject::isPressed const):
(WebCore::AXIsolatedObject::isUnvisited const):
(WebCore::AXIsolatedObject::isLinked const):
(WebCore::AXIsolatedObject::isVisible const):
(WebCore::AXIsolatedObject::isCollapsed const):
(WebCore::AXIsolatedObject::isSelectedOptionActive const):
(WebCore::AXIsolatedObject::hasBoldFont const):
(WebCore::AXIsolatedObject::hasItalicFont const):
(WebCore::AXIsolatedObject::hasMisspelling const):
(WebCore::AXIsolatedObject::hasPlainText const):
(WebCore::AXIsolatedObject::hasSameFont const):
(WebCore::AXIsolatedObject::hasSameFontColor const):
(WebCore::AXIsolatedObject::hasSameStyle const):
(WebCore::AXIsolatedObject::isStaticText const):
(WebCore::AXIsolatedObject::hasUnderline const):
(WebCore::AXIsolatedObject::hasHighlighting const):
(WebCore::AXIsolatedObject::element const):
(WebCore::AXIsolatedObject::node const):
(WebCore::AXIsolatedObject::renderer const):
(WebCore::AXIsolatedObject::defaultObjectInclusion const):
(WebCore::AXIsolatedObject::accessibilityIsIgnoredByDefault const):
(WebCore::AXIsolatedObject::stepValueForRange const):
(WebCore::AXIsolatedObject::selectedListItem):
(WebCore::AXIsolatedObject::ariaActiveDescendantReferencingElements const):
(WebCore::AXIsolatedObject::ariaControlsReferencingElements const):
(WebCore::AXIsolatedObject::ariaDescribedByElements const):
(WebCore::AXIsolatedObject::ariaDescribedByReferencingElements const):
(WebCore::AXIsolatedObject::ariaDetailsReferencingElements const):
(WebCore::AXIsolatedObject::ariaErrorMessageReferencingElements const):
(WebCore::AXIsolatedObject::ariaFlowToReferencingElements const):
(WebCore::AXIsolatedObject::ariaLabelledByElements const):
(WebCore::AXIsolatedObject::ariaLabelledByReferencingElements const):
(WebCore::AXIsolatedObject::ariaOwnsReferencingElements const):
(WebCore::AXIsolatedObject::hasDatalist const):
(WebCore::AXIsolatedObject::supportsHasPopup const):
(WebCore::AXIsolatedObject::supportsPressed const):
(WebCore::AXIsolatedObject::supportsChecked const):
(WebCore::AXIsolatedObject::ignoredFromModalPresence const):
(WebCore::AXIsolatedObject::isModalDescendant const):
(WebCore::AXIsolatedObject::isModalNode const):
(WebCore::AXIsolatedObject::elementAccessibilityHitTest const):
(WebCore::AXIsolatedObject::firstChild const):
(WebCore::AXIsolatedObject::lastChild const):
(WebCore::AXIsolatedObject::previousSibling const):
(WebCore::AXIsolatedObject::nextSibling const):
(WebCore::AXIsolatedObject::nextSiblingUnignored const):
(WebCore::AXIsolatedObject::previousSiblingUnignored const):
(WebCore::AXIsolatedObject::parentObjectIfExists const):
(WebCore::AXIsolatedObject::isDescendantOfBarrenParent const):
(WebCore::AXIsolatedObject::isDescendantOfRole const):
(WebCore::AXIsolatedObject::observableObject const):
(WebCore::AXIsolatedObject::correspondingLabelForControlElement const):
(WebCore::AXIsolatedObject::correspondingControlForLabelElement const):
(WebCore::AXIsolatedObject::isPresentationalChildOfAriaRole const):
(WebCore::AXIsolatedObject::ariaRoleHasPresentationalChildren const):
(WebCore::AXIsolatedObject::inheritsPresentationalRole const):
(WebCore::AXIsolatedObject::setAccessibleName):
(WebCore::AXIsolatedObject::hasAttributesRequiredForInclusion const):
(WebCore::AXIsolatedObject::accessibilityDescription const):
(WebCore::AXIsolatedObject::title const):
(WebCore::AXIsolatedObject::helpText const):
(WebCore::AXIsolatedObject::isARIAStaticText const):
(WebCore::AXIsolatedObject::stringValue const):
(WebCore::AXIsolatedObject::text const):
(WebCore::AXIsolatedObject::ariaLabeledByAttribute const):
(WebCore::AXIsolatedObject::ariaDescribedByAttribute const):
(WebCore::AXIsolatedObject::accessibleNameDerivesFromContent const):
(WebCore::AXIsolatedObject::elementsFromAttribute const):
(WebCore::AXIsolatedObject::axObjectCache const):
(WebCore::AXIsolatedObject::anchorElement const):
(WebCore::AXIsolatedObject::actionElement const):
(WebCore::AXIsolatedObject::elementPath const):
(WebCore::AXIsolatedObject::supportsPath const):
(WebCore::AXIsolatedObject::textIteratorBehaviorForTextRange const):
(WebCore::AXIsolatedObject::widget const):
(WebCore::AXIsolatedObject::widgetForAttachmentView const):
(WebCore::AXIsolatedObject::page const):
(WebCore::AXIsolatedObject::document const):
(WebCore::AXIsolatedObject::documentFrameView const):
(WebCore::AXIsolatedObject::frame const):
(WebCore::AXIsolatedObject::mainFrame const):
(WebCore::AXIsolatedObject::topDocument const):
(WebCore::AXIsolatedObject::scrollViewAncestor const):
(WebCore::AXIsolatedObject::childrenChanged):
(WebCore::AXIsolatedObject::textChanged):
(WebCore::AXIsolatedObject::updateAccessibilityRole):
(WebCore::AXIsolatedObject::addChildren):
(WebCore::AXIsolatedObject::addChild):
(WebCore::AXIsolatedObject::insertChild):
(WebCore::AXIsolatedObject::shouldIgnoreAttributeRole const):
(WebCore::AXIsolatedObject::canHaveChildren const):
(WebCore::AXIsolatedObject::hasChildren const):
(WebCore::AXIsolatedObject::setNeedsToUpdateChildren):
(WebCore::AXIsolatedObject::setNeedsToUpdateSubtree):
(WebCore::AXIsolatedObject::clearChildren):
(WebCore::AXIsolatedObject::needsToUpdateChildren const):
(WebCore::AXIsolatedObject::detachFromParent):
(WebCore::AXIsolatedObject::shouldFocusActiveDescendant const):
(WebCore::AXIsolatedObject::activeDescendant const):
(WebCore::AXIsolatedObject::handleActiveDescendantChanged):
(WebCore::AXIsolatedObject::handleAriaExpandedChanged):
(WebCore::AXIsolatedObject::isDescendantOfObject const):
(WebCore::AXIsolatedObject::isAncestorOfObject const):
(WebCore::AXIsolatedObject::firstAnonymousBlockChild const):
(WebCore::AXIsolatedObject::hasAttribute const):
(WebCore::AXIsolatedObject::getAttribute const):
(WebCore::AXIsolatedObject::hasTagName const):
(WebCore::AXIsolatedObject::stringValueForMSAA const):
(WebCore::AXIsolatedObject::stringRoleForMSAA const):
(WebCore::AXIsolatedObject::nameForMSAA const):
(WebCore::AXIsolatedObject::descriptionForMSAA const):
(WebCore::AXIsolatedObject::roleValueForMSAA const):
(WebCore::AXIsolatedObject::passwordFieldValue const):
(WebCore::AXIsolatedObject::liveRegionAncestor const):
(WebCore::AXIsolatedObject::hasContentEditableAttributeSet const):
(WebCore::AXIsolatedObject::supportsReadOnly const):
(WebCore::AXIsolatedObject::supportsAutoComplete const):
(WebCore::AXIsolatedObject::supportsARIAAttributes const):
(WebCore::AXIsolatedObject::scrollByPage const):
(WebCore::AXIsolatedObject::scrollPosition const):
(WebCore::AXIsolatedObject::scrollContentsSize const):
(WebCore::AXIsolatedObject::scrollVisibleContentRect const):
(WebCore::AXIsolatedObject::scrollToMakeVisible const):
(WebCore::AXIsolatedObject::lastKnownIsIgnoredValue):
(WebCore::AXIsolatedObject::setLastKnownIsIgnoredValue):
(WebCore::AXIsolatedObject::notifyIfIgnoredValueChanged):
(WebCore::AXIsolatedObject::isMathScriptObject const):
(WebCore::AXIsolatedObject::isMathMultiscriptObject const):
(WebCore::AXIsolatedObject::isAXHidden const):
(WebCore::AXIsolatedObject::isDOMHidden const):
(WebCore::AXIsolatedObject::isHidden const):
(WebCore::AXIsolatedObject::overrideAttachmentParent):
(WebCore::AXIsolatedObject::accessibilityIgnoreAttachment const):
(WebCore::AXIsolatedObject::accessibilityPlatformIncludesObject const):
(WebCore::AXIsolatedObject::hasApplePDFAnnotationAttribute const):
(WebCore::AXIsolatedObject::ancestorAccessibilityScrollView const):
(WebCore::AXIsolatedObject::setIsIgnoredFromParentData):
(WebCore::AXIsolatedObject::clearIsIgnoredFromParentData):
(WebCore::AXIsolatedObject::setIsIgnoredFromParentDataForChild):
* accessibility/isolatedtree/AXIsolatedTreeNode.h:
* accessibility/mac/WebAccessibilityObjectWrapperMac.mm: Added
dispatching to the main thread some of the methods that cannot be run
in the secondary thread.
(performAccessibilityFunctionOnMainThread):
(retrieveAccessibilityValueFromMainThread):
(-[WebAccessibilityObjectWrapper attachmentView]):
(-[WebAccessibilityObjectWrapper screenToContents:]):
(-[WebAccessibilityObjectWrapper renderWidgetChildren]):
(-[WebAccessibilityObjectWrapper remoteAccessibilityParentObject]):
(-[WebAccessibilityObjectWrapper associatedPluginParent]):
(-[WebAccessibilityObjectWrapper subrole]):
(-[WebAccessibilityObjectWrapper scrollViewParent]):
(-[WebAccessibilityObjectWrapper windowElement:]):
(-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
(-[WebAccessibilityObjectWrapper ALLOW_DEPRECATED_IMPLEMENTATIONS_END]):
(-[WebAccessibilityObjectWrapper accessibilityShowContextMenu]):
(-[WebAccessibilityObjectWrapper _accessibilityShowContextMenu]):
(-[WebAccessibilityObjectWrapper _convertToNSRange:]):
(-[WebAccessibilityObjectWrapper _textMarkerForIndex:]):

LayoutTests:

The AXStart/EndTextMarker attributes were being computed for
AccessibilityObjects that had a renderer object. With this change,
AXStart/EndTextMarker are computed for all AccessibilityObjects. Thus
the expected output for the following tests changed from null value for
these attributes to valid object values.

* accessibility/image-map2-expected.txt:
* accessibility/mac/document-links-expected.txt:
* accessibility/table-attributes-expected.txt:
* accessibility/table-sections-expected.txt:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@253261 268f45cc-cd09-0410-ab3c-d52691b4dbfc

22 files changed:
LayoutTests/ChangeLog
LayoutTests/accessibility/image-map2-expected.txt
LayoutTests/accessibility/mac/document-links-expected.txt
LayoutTests/accessibility/table-attributes-expected.txt
LayoutTests/accessibility/table-sections-expected.txt
Source/WebCore/ChangeLog
Source/WebCore/accessibility/AXObjectCache.cpp
Source/WebCore/accessibility/AXObjectCache.h
Source/WebCore/accessibility/AccessibilityNodeObject.cpp
Source/WebCore/accessibility/AccessibilityObject.cpp
Source/WebCore/accessibility/AccessibilityObject.h
Source/WebCore/accessibility/AccessibilityObjectInterface.h
Source/WebCore/accessibility/AccessibilityRenderObject.cpp
Source/WebCore/accessibility/AccessibilityRenderObject.h
Source/WebCore/accessibility/AccessibilitySpinButton.h
Source/WebCore/accessibility/atk/WebKitAccessibleHyperlink.cpp
Source/WebCore/accessibility/atk/WebKitAccessibleInterfaceAction.cpp
Source/WebCore/accessibility/isolatedtree/AXIsolatedTree.cpp
Source/WebCore/accessibility/isolatedtree/AXIsolatedTree.h
Source/WebCore/accessibility/isolatedtree/AXIsolatedTreeNode.cpp
Source/WebCore/accessibility/isolatedtree/AXIsolatedTreeNode.h
Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm

index ede2f91..bb39f68 100644 (file)
@@ -1,3 +1,21 @@
+2019-12-07  Andres Gonzalez  <andresg_22@apple.com>
+
+        Implementation of additional attribute caching in the IsolatedTree.
+        https://bugs.webkit.org/show_bug.cgi?id=204918
+
+        Reviewed by Chris Fleizach.
+
+        The AXStart/EndTextMarker attributes were being computed for
+        AccessibilityObjects that had a renderer object. With this change,
+        AXStart/EndTextMarker are computed for all AccessibilityObjects. Thus
+        the expected output for the following tests changed from null value for
+        these attributes to valid object values.
+
+        * accessibility/image-map2-expected.txt:
+        * accessibility/mac/document-links-expected.txt:
+        * accessibility/table-attributes-expected.txt:
+        * accessibility/table-sections-expected.txt:
+
 2019-12-06  Devin Rousso  <drousso@apple.com>
 
         Web Inspector: Uncaught Exception: Missing node for given nodeId
index 0607bbd..4ce4690 100644 (file)
@@ -44,8 +44,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXLink>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXLink>
+AXEndTextMarker: <AXLink>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
@@ -78,8 +78,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXLink>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXLink>
+AXEndTextMarker: <AXLink>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
index bc9b5d6..bdbe60b 100644 (file)
@@ -14,8 +14,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXLink>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXLink>
+AXEndTextMarker: <AXLink>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
@@ -48,8 +48,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXLink>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXLink>
+AXEndTextMarker: <AXLink>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
index b18685c..d1538ee 100644 (file)
@@ -289,8 +289,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXColumn>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXColumn>
+AXEndTextMarker: <AXColumn>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
@@ -323,8 +323,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXColumn>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXColumn>
+AXEndTextMarker: <AXColumn>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
@@ -357,8 +357,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXColumn>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXColumn>
+AXEndTextMarker: <AXColumn>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
@@ -391,8 +391,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXColumn>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXColumn>
+AXEndTextMarker: <AXColumn>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
@@ -425,8 +425,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXColumn>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXColumn>
+AXEndTextMarker: <AXColumn>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
@@ -1113,8 +1113,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXGroup>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXGroup>
+AXEndTextMarker: <AXGroup>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
index 4c55db0..c31e4fd 100644 (file)
@@ -261,8 +261,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXColumn>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXColumn>
+AXEndTextMarker: <AXColumn>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
@@ -295,8 +295,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXColumn>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXColumn>
+AXEndTextMarker: <AXColumn>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
@@ -329,8 +329,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXColumn>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXColumn>
+AXEndTextMarker: <AXColumn>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
@@ -943,8 +943,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXGroup>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXGroup>
+AXEndTextMarker: <AXGroup>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
@@ -1211,8 +1211,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXColumn>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXColumn>
+AXEndTextMarker: <AXColumn>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
@@ -1245,8 +1245,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXColumn>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXColumn>
+AXEndTextMarker: <AXColumn>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
@@ -1279,8 +1279,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXColumn>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXColumn>
+AXEndTextMarker: <AXColumn>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
@@ -1893,8 +1893,8 @@ AXFocused: 0
 AXEnabled: 1
 AXWindow: <AXGroup>
 AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: (null)
-AXEndTextMarker: (null)
+AXStartTextMarker: <AXGroup>
+AXEndTextMarker: <AXGroup>
 AXVisited: 0
 AXLinkedUIElements: <array of size 0>
 AXSelected: 0
index 4ada061..665482f 100644 (file)
@@ -1,3 +1,303 @@
+2019-12-07  Andres Gonzalez  <andresg_22@apple.com>
+
+        Implementation of additional attribute caching in the IsolatedTree.
+        https://bugs.webkit.org/show_bug.cgi?id=204918
+
+        Reviewed by Chris Fleizach.
+
+        No new tests, no new functionality. Updated several tests to fixed
+        expected output.
+
+        - Implementation of around 200 methods in the AXIsolatedObject class.
+        - The pending method implementations have an ASSERT_NOT_REACHED.
+        - Support for dispatching to the main thread some
+        WebAccessibilityObjectWrapper methods that cannot be run in the
+        secondary thread.
+
+        * accessibility/AXObjectCache.cpp:
+        (WebCore::AXObjectCache::createIsolatedTreeHierarchy):
+        (WebCore::AXObjectCache::generateIsolatedTree):
+        * accessibility/AXObjectCache.h:
+        * accessibility/AccessibilityNodeObject.cpp:
+        (WebCore::AccessibilityNodeObject::ariaLabeledByText const):
+        * accessibility/AccessibilityObject.cpp:
+        (WebCore::AccessibilityObject::actionVerb const):
+        (WebCore::AccessibilityObject::datetimeAttributeValue const):
+        (WebCore::AccessibilityObject::linkRelValue const):
+        (WebCore::AccessibilityObject::isInlineText const):
+        (WebCore::AccessibilityObject::identifierAttribute const):
+        (WebCore::AccessibilityObject::documentURI const):
+        (WebCore::AccessibilityObject::documentEncoding const):
+        (WebCore::AccessibilityObject::sessionID const):
+        (WebCore::AccessibilityObject::tagName const):
+        * accessibility/AccessibilityObject.h:
+        (WebCore::AccessibilityText::AccessibilityText):
+        (WebCore::AccessibilityObject::actionVerb const):
+        * accessibility/AccessibilityObjectInterface.h: Base implementation for
+        several isXXX methods that rely on the object roleValue.
+        (WebCore::AXCoreObject::isImageMap const):
+        (WebCore::AXCoreObject::isWebArea const):
+        (WebCore::AXCoreObject::isCheckbox const):
+        (WebCore::AXCoreObject::isRadioButton const):
+        (WebCore::AXCoreObject::isListBox const):
+        (WebCore::AXCoreObject::isSpinButton const):
+        (WebCore::AXCoreObject::isSwitch const):
+        (WebCore::AXCoreObject::isToggleButton const):
+        (WebCore::AXCoreObject::isTabList const):
+        (WebCore::AXCoreObject::isTabItem const):
+        (WebCore::AXCoreObject::isRadioGroup const):
+        (WebCore::AXCoreObject::isComboBox const):
+        (WebCore::AXCoreObject::isTree const):
+        (WebCore::AXCoreObject::isTreeGrid const):
+        (WebCore::AXCoreObject::isTreeItem const):
+        (WebCore::AXCoreObject::isScrollbar const):
+        (WebCore::AXCoreObject::isListItem const):
+        (WebCore::AXCoreObject::isCheckboxOrRadio const):
+        (WebCore::AXCoreObject::isScrollView const):
+        (WebCore::AXCoreObject::isCanvas const):
+        (WebCore::AXCoreObject::isPopUpButton const):
+        (WebCore::AXCoreObject::isColorWell const):
+        (WebCore::AXCoreObject::isSplitter const):
+        (WebCore::AXCoreObject::isToolbar const):
+        (WebCore::AXCoreObject::isSummary const):
+        * accessibility/AccessibilityRenderObject.cpp:
+        (WebCore::AccessibilityRenderObject::accessKey const):
+        (WebCore::AccessibilityRenderObject::actionVerb const):
+        * accessibility/AccessibilityRenderObject.h:
+        * accessibility/AccessibilitySpinButton.h:
+        * accessibility/isolatedtree/AXIsolatedTree.cpp:
+        (WebCore::AXIsolatedTree::setRootNode):
+        (WebCore::AXIsolatedTree::setRoot): Renamed setRootNode.
+        * accessibility/isolatedtree/AXIsolatedTree.h:
+        * accessibility/isolatedtree/AXIsolatedTreeNode.cpp: Implementation of
+        around 200 methods in the AXIsolatedObject class. The methods that are
+        pending, have a stub implemetation with an ASSERT_NOT_REACHED.
+        (WebCore::AXIsolatedObject::AXIsolatedObject):
+        (WebCore::AXIsolatedObject::create):
+        (WebCore::AXIsolatedObject::initializeAttributeData):
+        (WebCore::AXIsolatedObject::setMathscripts):
+        (WebCore::AXIsolatedObject::setObjectVectorProperty):
+        (WebCore::AXIsolatedObject::isDetached const):
+        (WebCore::AXIsolatedObject::isDetachedFromParent):
+        (WebCore::AXIsolatedObject::accessibilityText const):
+        (WebCore::AXIsolatedObject::classList const):
+        (WebCore::AXIsolatedObject::sessionID const):
+        (WebCore::AXIsolatedObject::documentURI const):
+        (WebCore::AXIsolatedObject::preventKeyboardDOMEventDispatch const):
+        (WebCore::AXIsolatedObject::documentEncoding const):
+        (WebCore::AXIsolatedObject::insertMathPairs):
+        (WebCore::AXIsolatedObject::mathPrescripts):
+        (WebCore::AXIsolatedObject::mathPostscripts):
+        (WebCore::AXIsolatedObject::scrollBar):
+        (WebCore::AXIsolatedObject::colorValue const):
+        (WebCore::AXIsolatedObject::intPointAttributeValue const):
+        (WebCore::AXIsolatedObject::vectorAttributeValue const):
+        (WebCore::AXIsolatedObject::optionSetAttributeValue const):
+        (WebCore::AXIsolatedObject::uint64AttributeValue const):
+        (WebCore::AXIsolatedObject::urlAttributeValue const):
+        (WebCore::AXIsolatedObject::colorAttributeValue const):
+        (WebCore::AXIsolatedObject::floatAttributeValue const):
+        (WebCore::AXIsolatedObject::fillChildrenVectorForProperty const):
+        (WebCore::AXIsolatedObject::replaceTextInRange):
+        (WebCore::AXIsolatedObject::insertText):
+        (WebCore::AXIsolatedObject::press):
+        (WebCore::AXIsolatedObject::performDefaultAction):
+        (WebCore::AXIsolatedObject::isAccessibilityObject const):
+        (WebCore::AXIsolatedObject::isAccessibilityNodeObject const):
+        (WebCore::AXIsolatedObject::isAccessibilityRenderObject const):
+        (WebCore::AXIsolatedObject::isAccessibilityScrollbar const):
+        (WebCore::AXIsolatedObject::isAccessibilityScrollView const):
+        (WebCore::AXIsolatedObject::isAccessibilitySVGRoot const):
+        (WebCore::AXIsolatedObject::isAccessibilitySVGElement const):
+        (WebCore::AXIsolatedObject::containsText const):
+        (WebCore::AXIsolatedObject::isAttachmentElement const):
+        (WebCore::AXIsolatedObject::isNativeImage const):
+        (WebCore::AXIsolatedObject::isImageButton const):
+        (WebCore::AXIsolatedObject::isContainedByPasswordField const):
+        (WebCore::AXIsolatedObject::passwordFieldOrContainingPasswordField):
+        (WebCore::AXIsolatedObject::isNativeTextControl const):
+        (WebCore::AXIsolatedObject::isNativeListBox const):
+        (WebCore::AXIsolatedObject::isListBoxOption const):
+        (WebCore::AXIsolatedObject::isSliderThumb const):
+        (WebCore::AXIsolatedObject::isInputSlider const):
+        (WebCore::AXIsolatedObject::isLabel const):
+        (WebCore::AXIsolatedObject::isDataTable const):
+        (WebCore::AXIsolatedObject::isImageMapLink const):
+        (WebCore::AXIsolatedObject::isNativeSpinButton const):
+        (WebCore::AXIsolatedObject::isSpinButtonPart const):
+        (WebCore::AXIsolatedObject::isMockObject const):
+        (WebCore::AXIsolatedObject::isMediaObject const):
+        (WebCore::AXIsolatedObject::isARIATextControl const):
+        (WebCore::AXIsolatedObject::isNonNativeTextControl const):
+        (WebCore::AXIsolatedObject::isBlockquote const):
+        (WebCore::AXIsolatedObject::isLandmark const):
+        (WebCore::AXIsolatedObject::isFigureElement const):
+        (WebCore::AXIsolatedObject::isKeyboardFocusable const):
+        (WebCore::AXIsolatedObject::isHovered const):
+        (WebCore::AXIsolatedObject::isIndeterminate const):
+        (WebCore::AXIsolatedObject::isLoaded const):
+        (WebCore::AXIsolatedObject::isOnScreen const):
+        (WebCore::AXIsolatedObject::isOffScreen const):
+        (WebCore::AXIsolatedObject::isPressed const):
+        (WebCore::AXIsolatedObject::isUnvisited const):
+        (WebCore::AXIsolatedObject::isLinked const):
+        (WebCore::AXIsolatedObject::isVisible const):
+        (WebCore::AXIsolatedObject::isCollapsed const):
+        (WebCore::AXIsolatedObject::isSelectedOptionActive const):
+        (WebCore::AXIsolatedObject::hasBoldFont const):
+        (WebCore::AXIsolatedObject::hasItalicFont const):
+        (WebCore::AXIsolatedObject::hasMisspelling const):
+        (WebCore::AXIsolatedObject::hasPlainText const):
+        (WebCore::AXIsolatedObject::hasSameFont const):
+        (WebCore::AXIsolatedObject::hasSameFontColor const):
+        (WebCore::AXIsolatedObject::hasSameStyle const):
+        (WebCore::AXIsolatedObject::isStaticText const):
+        (WebCore::AXIsolatedObject::hasUnderline const):
+        (WebCore::AXIsolatedObject::hasHighlighting const):
+        (WebCore::AXIsolatedObject::element const):
+        (WebCore::AXIsolatedObject::node const):
+        (WebCore::AXIsolatedObject::renderer const):
+        (WebCore::AXIsolatedObject::defaultObjectInclusion const):
+        (WebCore::AXIsolatedObject::accessibilityIsIgnoredByDefault const):
+        (WebCore::AXIsolatedObject::stepValueForRange const):
+        (WebCore::AXIsolatedObject::selectedListItem):
+        (WebCore::AXIsolatedObject::ariaActiveDescendantReferencingElements const):
+        (WebCore::AXIsolatedObject::ariaControlsReferencingElements const):
+        (WebCore::AXIsolatedObject::ariaDescribedByElements const):
+        (WebCore::AXIsolatedObject::ariaDescribedByReferencingElements const):
+        (WebCore::AXIsolatedObject::ariaDetailsReferencingElements const):
+        (WebCore::AXIsolatedObject::ariaErrorMessageReferencingElements const):
+        (WebCore::AXIsolatedObject::ariaFlowToReferencingElements const):
+        (WebCore::AXIsolatedObject::ariaLabelledByElements const):
+        (WebCore::AXIsolatedObject::ariaLabelledByReferencingElements const):
+        (WebCore::AXIsolatedObject::ariaOwnsReferencingElements const):
+        (WebCore::AXIsolatedObject::hasDatalist const):
+        (WebCore::AXIsolatedObject::supportsHasPopup const):
+        (WebCore::AXIsolatedObject::supportsPressed const):
+        (WebCore::AXIsolatedObject::supportsChecked const):
+        (WebCore::AXIsolatedObject::ignoredFromModalPresence const):
+        (WebCore::AXIsolatedObject::isModalDescendant const):
+        (WebCore::AXIsolatedObject::isModalNode const):
+        (WebCore::AXIsolatedObject::elementAccessibilityHitTest const):
+        (WebCore::AXIsolatedObject::firstChild const):
+        (WebCore::AXIsolatedObject::lastChild const):
+        (WebCore::AXIsolatedObject::previousSibling const):
+        (WebCore::AXIsolatedObject::nextSibling const):
+        (WebCore::AXIsolatedObject::nextSiblingUnignored const):
+        (WebCore::AXIsolatedObject::previousSiblingUnignored const):
+        (WebCore::AXIsolatedObject::parentObjectIfExists const):
+        (WebCore::AXIsolatedObject::isDescendantOfBarrenParent const):
+        (WebCore::AXIsolatedObject::isDescendantOfRole const):
+        (WebCore::AXIsolatedObject::observableObject const):
+        (WebCore::AXIsolatedObject::correspondingLabelForControlElement const):
+        (WebCore::AXIsolatedObject::correspondingControlForLabelElement const):
+        (WebCore::AXIsolatedObject::isPresentationalChildOfAriaRole const):
+        (WebCore::AXIsolatedObject::ariaRoleHasPresentationalChildren const):
+        (WebCore::AXIsolatedObject::inheritsPresentationalRole const):
+        (WebCore::AXIsolatedObject::setAccessibleName):
+        (WebCore::AXIsolatedObject::hasAttributesRequiredForInclusion const):
+        (WebCore::AXIsolatedObject::accessibilityDescription const):
+        (WebCore::AXIsolatedObject::title const):
+        (WebCore::AXIsolatedObject::helpText const):
+        (WebCore::AXIsolatedObject::isARIAStaticText const):
+        (WebCore::AXIsolatedObject::stringValue const):
+        (WebCore::AXIsolatedObject::text const):
+        (WebCore::AXIsolatedObject::ariaLabeledByAttribute const):
+        (WebCore::AXIsolatedObject::ariaDescribedByAttribute const):
+        (WebCore::AXIsolatedObject::accessibleNameDerivesFromContent const):
+        (WebCore::AXIsolatedObject::elementsFromAttribute const):
+        (WebCore::AXIsolatedObject::axObjectCache const):
+        (WebCore::AXIsolatedObject::anchorElement const):
+        (WebCore::AXIsolatedObject::actionElement const):
+        (WebCore::AXIsolatedObject::elementPath const):
+        (WebCore::AXIsolatedObject::supportsPath const):
+        (WebCore::AXIsolatedObject::textIteratorBehaviorForTextRange const):
+        (WebCore::AXIsolatedObject::widget const):
+        (WebCore::AXIsolatedObject::widgetForAttachmentView const):
+        (WebCore::AXIsolatedObject::page const):
+        (WebCore::AXIsolatedObject::document const):
+        (WebCore::AXIsolatedObject::documentFrameView const):
+        (WebCore::AXIsolatedObject::frame const):
+        (WebCore::AXIsolatedObject::mainFrame const):
+        (WebCore::AXIsolatedObject::topDocument const):
+        (WebCore::AXIsolatedObject::scrollViewAncestor const):
+        (WebCore::AXIsolatedObject::childrenChanged):
+        (WebCore::AXIsolatedObject::textChanged):
+        (WebCore::AXIsolatedObject::updateAccessibilityRole):
+        (WebCore::AXIsolatedObject::addChildren):
+        (WebCore::AXIsolatedObject::addChild):
+        (WebCore::AXIsolatedObject::insertChild):
+        (WebCore::AXIsolatedObject::shouldIgnoreAttributeRole const):
+        (WebCore::AXIsolatedObject::canHaveChildren const):
+        (WebCore::AXIsolatedObject::hasChildren const):
+        (WebCore::AXIsolatedObject::setNeedsToUpdateChildren):
+        (WebCore::AXIsolatedObject::setNeedsToUpdateSubtree):
+        (WebCore::AXIsolatedObject::clearChildren):
+        (WebCore::AXIsolatedObject::needsToUpdateChildren const):
+        (WebCore::AXIsolatedObject::detachFromParent):
+        (WebCore::AXIsolatedObject::shouldFocusActiveDescendant const):
+        (WebCore::AXIsolatedObject::activeDescendant const):
+        (WebCore::AXIsolatedObject::handleActiveDescendantChanged):
+        (WebCore::AXIsolatedObject::handleAriaExpandedChanged):
+        (WebCore::AXIsolatedObject::isDescendantOfObject const):
+        (WebCore::AXIsolatedObject::isAncestorOfObject const):
+        (WebCore::AXIsolatedObject::firstAnonymousBlockChild const):
+        (WebCore::AXIsolatedObject::hasAttribute const):
+        (WebCore::AXIsolatedObject::getAttribute const):
+        (WebCore::AXIsolatedObject::hasTagName const):
+        (WebCore::AXIsolatedObject::stringValueForMSAA const):
+        (WebCore::AXIsolatedObject::stringRoleForMSAA const):
+        (WebCore::AXIsolatedObject::nameForMSAA const):
+        (WebCore::AXIsolatedObject::descriptionForMSAA const):
+        (WebCore::AXIsolatedObject::roleValueForMSAA const):
+        (WebCore::AXIsolatedObject::passwordFieldValue const):
+        (WebCore::AXIsolatedObject::liveRegionAncestor const):
+        (WebCore::AXIsolatedObject::hasContentEditableAttributeSet const):
+        (WebCore::AXIsolatedObject::supportsReadOnly const):
+        (WebCore::AXIsolatedObject::supportsAutoComplete const):
+        (WebCore::AXIsolatedObject::supportsARIAAttributes const):
+        (WebCore::AXIsolatedObject::scrollByPage const):
+        (WebCore::AXIsolatedObject::scrollPosition const):
+        (WebCore::AXIsolatedObject::scrollContentsSize const):
+        (WebCore::AXIsolatedObject::scrollVisibleContentRect const):
+        (WebCore::AXIsolatedObject::scrollToMakeVisible const):
+        (WebCore::AXIsolatedObject::lastKnownIsIgnoredValue):
+        (WebCore::AXIsolatedObject::setLastKnownIsIgnoredValue):
+        (WebCore::AXIsolatedObject::notifyIfIgnoredValueChanged):
+        (WebCore::AXIsolatedObject::isMathScriptObject const):
+        (WebCore::AXIsolatedObject::isMathMultiscriptObject const):
+        (WebCore::AXIsolatedObject::isAXHidden const):
+        (WebCore::AXIsolatedObject::isDOMHidden const):
+        (WebCore::AXIsolatedObject::isHidden const):
+        (WebCore::AXIsolatedObject::overrideAttachmentParent):
+        (WebCore::AXIsolatedObject::accessibilityIgnoreAttachment const):
+        (WebCore::AXIsolatedObject::accessibilityPlatformIncludesObject const):
+        (WebCore::AXIsolatedObject::hasApplePDFAnnotationAttribute const):
+        (WebCore::AXIsolatedObject::ancestorAccessibilityScrollView const):
+        (WebCore::AXIsolatedObject::setIsIgnoredFromParentData):
+        (WebCore::AXIsolatedObject::clearIsIgnoredFromParentData):
+        (WebCore::AXIsolatedObject::setIsIgnoredFromParentDataForChild):
+        * accessibility/isolatedtree/AXIsolatedTreeNode.h:
+        * accessibility/mac/WebAccessibilityObjectWrapperMac.mm: Added
+        dispatching to the main thread some of the methods that cannot be run
+        in the secondary thread.
+        (performAccessibilityFunctionOnMainThread):
+        (retrieveAccessibilityValueFromMainThread):
+        (-[WebAccessibilityObjectWrapper attachmentView]):
+        (-[WebAccessibilityObjectWrapper screenToContents:]):
+        (-[WebAccessibilityObjectWrapper renderWidgetChildren]):
+        (-[WebAccessibilityObjectWrapper remoteAccessibilityParentObject]):
+        (-[WebAccessibilityObjectWrapper associatedPluginParent]):
+        (-[WebAccessibilityObjectWrapper subrole]):
+        (-[WebAccessibilityObjectWrapper scrollViewParent]):
+        (-[WebAccessibilityObjectWrapper windowElement:]):
+        (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
+        (-[WebAccessibilityObjectWrapper ALLOW_DEPRECATED_IMPLEMENTATIONS_END]):
+        (-[WebAccessibilityObjectWrapper accessibilityShowContextMenu]):
+        (-[WebAccessibilityObjectWrapper _accessibilityShowContextMenu]):
+        (-[WebAccessibilityObjectWrapper _convertToNSRange:]):
+        (-[WebAccessibilityObjectWrapper _textMarkerForIndex:]):
+
 2019-12-07  Zalan Bujtas  <zalan@apple.com>
 
         [LFC][IFC] Initialize InlineLayoutUnit variables to 0
index 03e6004..5a20244 100644 (file)
@@ -3064,9 +3064,9 @@ void AXObjectCache::performDeferredCacheUpdate()
 }
     
 #if ENABLE(ACCESSIBILITY_ISOLATED_TREE)
-Ref<AXIsolatedObject> AXObjectCache::createIsolatedTreeHierarchy(AXCoreObject& object, AXID parentID, AXObjectCache* axObjectCache, AXIsolatedTree& tree, Vector<Ref<AXIsolatedObject>>& nodeChanges)
+Ref<AXIsolatedObject> AXObjectCache::createIsolatedTreeHierarchy(AXCoreObject& object, AXID parentID, AXObjectCache* axObjectCache, AXIsolatedTree& tree, Vector<Ref<AXIsolatedObject>>& nodeChanges, bool isRoot)
 {
-    auto isolatedTreeNode = AXIsolatedObject::create(object);
+    auto isolatedTreeNode = AXIsolatedObject::create(object, isRoot);
     nodeChanges.append(isolatedTreeNode.copyRef());
 
     isolatedTreeNode->setTreeIdentifier(tree.treeIdentifier());
@@ -3074,7 +3074,7 @@ Ref<AXIsolatedObject> AXObjectCache::createIsolatedTreeHierarchy(AXCoreObject& o
     axObjectCache->attachWrapper(&isolatedTreeNode.get());
 
     for (const auto& child : object.children()) {
-        auto staticChild = createIsolatedTreeHierarchy(*child, isolatedTreeNode->objectID(), axObjectCache, tree, nodeChanges);
+        auto staticChild = createIsolatedTreeHierarchy(*child, isolatedTreeNode->objectID(), axObjectCache, tree, nodeChanges, false);
         isolatedTreeNode->appendChild(staticChild->objectID());
     }
 
@@ -3098,8 +3098,8 @@ Ref<AXIsolatedTree> AXObjectCache::generateIsolatedTree(PageIdentifier pageID, D
     auto* axRoot = axObjectCache->getOrCreate(document.view());
     if (axRoot) {
         Vector<Ref<AXIsolatedObject>> nodeChanges;
-        auto isolatedRoot = createIsolatedTreeHierarchy(*axRoot, InvalidAXID, axObjectCache, *tree, nodeChanges);
-        tree->setRoot(isolatedRoot);
+        auto isolatedRoot = createIsolatedTreeHierarchy(*axRoot, InvalidAXID, axObjectCache, *tree, nodeChanges, true);
+        tree->setRootNode(isolatedRoot);
         tree->appendNodeChanges(nodeChanges);
     }
 
index e59e220..802a755 100644 (file)
@@ -198,7 +198,7 @@ private:
     static AXCoreObject* isolatedTreeFocusedObject(Document&);
     void setIsolatedTreeFocusedObject(Node*);
     static Ref<AXIsolatedTree> generateIsolatedTree(PageIdentifier, Document&);
-    static Ref<AXIsolatedObject> createIsolatedTreeHierarchy(AXCoreObject&, AXID, AXObjectCache*, AXIsolatedTree&, Vector<Ref<AXIsolatedObject>>&);
+    static Ref<AXIsolatedObject> createIsolatedTreeHierarchy(AXCoreObject&, AXID, AXObjectCache*, AXIsolatedTree&, Vector<Ref<AXIsolatedObject>>&, bool isRoot);
 #endif
 
 public:
index 61b7a4e..16b6240 100644 (file)
@@ -1513,11 +1513,11 @@ void AccessibilityNodeObject::ariaLabeledByText(Vector<AccessibilityText>& textO
         Vector<Element*> elements;
         ariaLabeledByElements(elements);
 
-        Vector<RefPtr<AccessibilityObject>> axElements;
+        Vector<AXCoreObject*> axElements;
         for (const auto& element : elements)
             axElements.append(objectCache->getOrCreate(element));
         
-        textOrder.append(AccessibilityText(ariaLabeledBy, AccessibilityTextSource::Alternative, WTFMove(axElements)));
+        textOrder.append(AccessibilityText(ariaLabeledBy, AccessibilityTextSource::Alternative, axElements));
     }
 }
     
index 80ac1ee..81f43b4 100644 (file)
@@ -2094,7 +2094,7 @@ const String AccessibilityObject::defaultLiveRegionStatusForRole(AccessibilityRo
 }
     
 #if ENABLE(ACCESSIBILITY)
-const String& AccessibilityObject::actionVerb() const
+String AccessibilityObject::actionVerb() const
 {
 #if !PLATFORM(IOS_FAMILY)
     // FIXME: Need to add verbs for select elements.
@@ -2723,16 +2723,21 @@ bool AccessibilityObject::supportsDatetimeAttribute() const
     return hasTagName(insTag) || hasTagName(delTag) || hasTagName(timeTag);
 }
 
-const AtomString& AccessibilityObject::datetimeAttributeValue() const
+String AccessibilityObject::datetimeAttributeValue() const
 {
     return getAttribute(datetimeAttr);
 }
     
-const AtomString& AccessibilityObject::linkRelValue() const
+String AccessibilityObject::linkRelValue() const
 {
     return getAttribute(relAttr);
 }
     
+bool AccessibilityObject::isInlineText() const
+{
+    return is<RenderInline>(renderer());
+}
+
 const String AccessibilityObject::keyShortcutsValue() const
 {
     return getAttribute(aria_keyshortcutsAttr);
@@ -2968,7 +2973,7 @@ int AccessibilityObject::posInSet() const
     return getAttribute(aria_posinsetAttr).toInt();
 }
     
-const AtomString& AccessibilityObject::identifierAttribute() const
+String AccessibilityObject::identifierAttribute() const
 {
     return getAttribute(idAttr);
 }
@@ -3635,6 +3640,37 @@ AccessibilityObject* AccessibilityObject::radioGroupAncestor() const
     });
 }
 
+String AccessibilityObject::documentURI() const
+{
+    if (auto* document = this->document())
+        return document->documentURI();
+    return String();
+}
+
+String AccessibilityObject::documentEncoding() const
+{
+    if (auto* document = this->document())
+        return document->encoding();
+    return String();
+}
+
+uint64_t AccessibilityObject::sessionID() const
+{
+    if (auto* document = topDocument()) {
+        if (auto* page = document->page())
+            return page->sessionID().toUInt64();
+    }
+    return 0;
+}
+
+String AccessibilityObject::tagName() const
+{
+    if (Element* element = this->element())
+        return element->localName();
+
+    return String();
+}
+
 bool AccessibilityObject::isStyleFormatGroup() const
 {
     Node* node = this->node();
index 4cbdf7f..162e7c0 100644 (file)
@@ -66,41 +66,30 @@ class IntPoint;
 class IntSize;
 class ScrollableArea;
 
-enum class AccessibilityTextSource {
-    Alternative,
-    Children,
-    Summary,
-    Help,
-    Visible,
-    TitleTag,
-    Placeholder,
-    LabelByElement,
-    Title,
-    Subtitle,
-    Action,
-};
-    
 struct AccessibilityText {
     String text;
     AccessibilityTextSource textSource;
-    Vector<RefPtr<AccessibilityObject>> textElements;
+    Vector<RefPtr<AXCoreObject>> textElements;
     
     AccessibilityText(const String& t, const AccessibilityTextSource& s)
         : text(t)
         , textSource(s)
     { }
 
-    AccessibilityText(const String& t, const AccessibilityTextSource& s, Vector<RefPtr<AccessibilityObject>> elements)
+    AccessibilityText(const String& t, const AccessibilityTextSource& s, Vector<AXCoreObject*> elements)
         : text(t)
         , textSource(s)
-        , textElements(WTFMove(elements))
-    { }
+    {
+        textElements.reserveCapacity(elements.size());
+        for (auto element : elements)
+            textElements.uncheckedAppend(element);
+    }
 
-    AccessibilityText(const String& t, const AccessibilityTextSource& s, RefPtr<AccessibilityObject>&& element)
+    AccessibilityText(const String& t, const AccessibilityTextSource& s, AXCoreObject* element)
         : text(t)
         , textSource(s)
     {
-        textElements.append(WTFMove(element));
+        textElements.append(element);
     }
 };
 
@@ -137,7 +126,6 @@ public:
     bool isHeading() const override { return false; }
     bool isLink() const override { return false; }
     bool isImage() const override { return false; }
-    bool isImageMap() const override { return roleValue() == AccessibilityRole::ImageMap; }
     bool isNativeImage() const override { return false; }
     bool isImageButton() const override { return false; }
     bool isPasswordField() const override { return false; }
@@ -145,11 +133,7 @@ public:
     AccessibilityObject* passwordFieldOrContainingPasswordField() override { return nullptr; }
     bool isNativeTextControl() const override { return false; }
     bool isSearchField() const override { return false; }
-    bool isWebArea() const override { return roleValue() == AccessibilityRole::WebArea; }
-    bool isCheckbox() const override { return roleValue() == AccessibilityRole::CheckBox; }
-    bool isRadioButton() const override { return roleValue() == AccessibilityRole::RadioButton; }
     bool isNativeListBox() const override { return false; }
-    bool isListBox() const override { return roleValue() == AccessibilityRole::ListBox; }
     bool isListBoxOption() const override { return false; }
     bool isAttachment() const override { return false; }
     bool isMediaTimeline() const override { return false; }
@@ -179,42 +163,22 @@ public:
     bool isMenuList() const override { return false; }
     bool isMenuListPopup() const override { return false; }
     bool isMenuListOption() const override { return false; }
-    bool isSpinButton() const override { return roleValue() == AccessibilityRole::SpinButton; }
     bool isNativeSpinButton() const override { return false; }
     bool isSpinButtonPart() const override { return false; }
     bool isMockObject() const override { return false; }
-    bool isMediaControlLabel() const override { return false; }
+    virtual bool isMediaControlLabel() const { return false; }
     bool isMediaObject() const override { return false; }
-    bool isSwitch() const override { return roleValue() == AccessibilityRole::Switch; }
-    bool isToggleButton() const override { return roleValue() == AccessibilityRole::ToggleButton; }
     bool isTextControl() const override;
     bool isARIATextControl() const override;
     bool isNonNativeTextControl() const override;
-    bool isTabList() const override { return roleValue() == AccessibilityRole::TabList; }
-    bool isTabItem() const override { return roleValue() == AccessibilityRole::Tab; }
-    bool isRadioGroup() const override { return roleValue() == AccessibilityRole::RadioGroup; }
-    bool isComboBox() const override { return roleValue() == AccessibilityRole::ComboBox; }
-    bool isTree() const override { return roleValue() == AccessibilityRole::Tree; }
-    bool isTreeGrid() const override { return roleValue() == AccessibilityRole::TreeGrid; }
-    bool isTreeItem() const override { return roleValue() == AccessibilityRole::TreeItem; }
-    bool isScrollbar() const override { return roleValue() == AccessibilityRole::ScrollBar; }
     bool isButton() const override;
-    bool isListItem() const override { return roleValue() == AccessibilityRole::ListItem; }
-    bool isCheckboxOrRadio() const override { return isCheckbox() || isRadioButton(); }
-    bool isScrollView() const override { return roleValue() == AccessibilityRole::ScrollArea; }
-    bool isCanvas() const override { return roleValue() == AccessibilityRole::Canvas; }
-    bool isPopUpButton() const override { return roleValue() == AccessibilityRole::PopUpButton; }
     bool isBlockquote() const override;
     bool isLandmark() const override;
-    bool isColorWell() const override { return roleValue() == AccessibilityRole::ColorWell; }
     bool isRangeControl() const override;
     bool isMeter() const override;
-    bool isSplitter() const override { return roleValue() == AccessibilityRole::Splitter; }
-    bool isToolbar() const override { return roleValue() == AccessibilityRole::Toolbar; }
     bool isStyleFormatGroup() const override;
     bool isFigureElement() const override;
     bool isKeyboardFocusable() const override;
-    bool isSummary() const override { return roleValue() == AccessibilityRole::Summary; }
     bool isOutput() const override;
 
     bool isChecked() const override { return false; }
@@ -255,7 +219,7 @@ public:
     bool hasHighlighting() const override;
 
     bool supportsDatetimeAttribute() const override;
-    const AtomString& datetimeAttributeValue() const override;
+    String datetimeAttributeValue() const override;
 
     bool canSetFocusAttribute() const override { return false; }
     bool canSetTextRangeAttributes() const override { return false; }
@@ -323,8 +287,8 @@ public:
     AccessibilitySortDirection sortDirection() const override;
     bool canvasHasFallbackContent() const override { return false; }
     bool supportsRangeValue() const override;
-    const AtomString& identifierAttribute() const override;
-    const AtomString& linkRelValue() const override;
+    String identifierAttribute() const override;
+    String linkRelValue() const override;
     void classList(Vector<String>&) const override;
     AccessibilityCurrentState currentState() const override;
     String currentValue() const override;
@@ -454,8 +418,8 @@ public:
     URL url() const override { return URL(); }
     VisibleSelection selection() const override { return VisibleSelection(); }
     String selectedText() const override { return String(); }
-    const AtomString& accessKey() const override { return nullAtom(); }
-    const String& actionVerb() const override;
+    String accessKey() const override { return nullAtom(); }
+    String actionVerb() const override;
     Widget* widget() const override { return nullptr; }
     Widget* widgetForAttachmentView() const override { return nullptr; }
     Page* page() const override;
@@ -468,6 +432,7 @@ public:
     String language() const override;
     // 1-based, to match the aria-level spec.
     unsigned hierarchicalLevel() const override { return 0; }
+    bool isInlineText() const override;
 
     void setFocused(bool) override { }
     void setSelectedText(const String&) override { }
@@ -528,6 +493,7 @@ public:
     bool hasAttribute(const QualifiedName&) const override;
     const AtomString& getAttribute(const QualifiedName&) const override;
     bool hasTagName(const QualifiedName&) const override;
+    String tagName() const override;
 
     VisiblePositionRange visiblePositionRange() const override { return VisiblePositionRange(); }
     VisiblePositionRange visiblePositionRangeForLine(unsigned) const override { return VisiblePositionRange(); }
@@ -629,6 +595,7 @@ public:
     bool supportsAutoComplete() const override;
     String autoCompleteValue() const override;
 
+    bool hasARIAValueNow() const override { return hasAttribute(HTMLNames::aria_valuenowAttr); }
     bool supportsARIAAttributes() const override;
 
     // CSS3 Speech properties.
@@ -750,6 +717,7 @@ public:
     String descriptionAttributeValue() const override;
     String helpTextAttributeValue() const override;
     String titleAttributeValue() const override;
+    bool hasApplePDFAnnotationAttribute() const override { return hasAttribute(HTMLNames::x_apple_pdf_annotationAttr); }
 #endif
 
 #if PLATFORM(COCOA) && !PLATFORM(IOS_FAMILY)
@@ -766,6 +734,10 @@ public:
     void clearIsIgnoredFromParentData() override { m_isIgnoredFromParentData = AccessibilityIsIgnoredFromParentData(); }
     void setIsIgnoredFromParentDataForChild(AXCoreObject*) override;
 
+    uint64_t sessionID() const override;
+    String documentURI() const override;
+    String documentEncoding() const override;
+
 protected:
     AXID m_id { 0 };
     AccessibilityChildrenVector m_children;
@@ -823,7 +795,7 @@ protected:
 
 #if !ENABLE(ACCESSIBILITY)
 inline const AccessibilityObject::AccessibilityChildrenVector& AccessibilityObject::children(bool) { return m_children; }
-inline const String& AccessibilityObject::actionVerb() const { return emptyString(); }
+inline String AccessibilityObject::actionVerb() const { return emptyString(); }
 inline int AccessibilityObject::lineForPosition(const VisiblePosition&) const { return -1; }
 inline void AccessibilityObject::updateBackingStore() { }
 #endif
index a2d5e88..91b9823 100644 (file)
@@ -234,6 +234,20 @@ enum class AccessibilitySearchDirection {
     Previous,
 };
 
+enum class AccessibilityTextSource {
+    Alternative,
+    Children,
+    Summary,
+    Help,
+    Visible,
+    TitleTag,
+    Placeholder,
+    LabelByElement,
+    Title,
+    Subtitle,
+    Action,
+};
+
 enum class AccessibilitySearchKey {
     AnyType = 1,
     Article,
@@ -479,7 +493,7 @@ public:
     virtual bool isHeading() const = 0;
     virtual bool isLink() const = 0;
     virtual bool isImage() const = 0;
-    virtual bool isImageMap() const = 0;
+    bool isImageMap() const { return roleValue() == AccessibilityRole::ImageMap; }
     virtual bool isNativeImage() const = 0;
     virtual bool isImageButton() const = 0;
     virtual bool isPasswordField() const = 0;
@@ -487,11 +501,11 @@ public:
     virtual AXCoreObject* passwordFieldOrContainingPasswordField() = 0;
     virtual bool isNativeTextControl() const = 0;
     virtual bool isSearchField() const = 0;
-    virtual bool isWebArea() const = 0;
-    virtual bool isCheckbox() const = 0;
-    virtual bool isRadioButton() const = 0;
+    bool isWebArea() const { return roleValue() == AccessibilityRole::WebArea; }
+    bool isCheckbox() const { return roleValue() == AccessibilityRole::CheckBox; }
+    bool isRadioButton() const { return roleValue() == AccessibilityRole::RadioButton; }
+    bool isListBox() const { return roleValue() == AccessibilityRole::ListBox; }
     virtual bool isNativeListBox() const = 0;
-    virtual bool isListBox() const = 0;
     virtual bool isListBoxOption() const = 0;
     virtual bool isAttachment() const = 0;
     virtual bool isMediaTimeline() const = 0;
@@ -521,42 +535,43 @@ public:
     virtual bool isMenuList() const = 0;
     virtual bool isMenuListPopup() const = 0;
     virtual bool isMenuListOption() const = 0;
-    virtual bool isSpinButton() const = 0;
+    bool isSpinButton() const { return roleValue() == AccessibilityRole::SpinButton; }
     virtual bool isNativeSpinButton() const = 0;
     virtual bool isSpinButtonPart() const = 0;
     virtual bool isMockObject() const = 0;
-    virtual bool isMediaControlLabel() const = 0;
     virtual bool isMediaObject() const = 0;
-    virtual bool isSwitch() const = 0;
-    virtual bool isToggleButton() const = 0;
+    bool isSwitch() const { return roleValue() == AccessibilityRole::Switch; }
+    bool isToggleButton() const { return roleValue() == AccessibilityRole::ToggleButton; }
     virtual bool isTextControl() const = 0;
     virtual bool isARIATextControl() const = 0;
     virtual bool isNonNativeTextControl() const = 0;
-    virtual bool isTabList() const = 0;
-    virtual bool isTabItem() const = 0;
-    virtual bool isRadioGroup() const = 0;
-    virtual bool isComboBox() const = 0;
-    virtual bool isTree() const = 0;
-    virtual bool isTreeGrid() const = 0;
-    virtual bool isTreeItem() const = 0;
-    virtual bool isScrollbar() const = 0;
+    bool isTabList() const { return roleValue() == AccessibilityRole::TabList; }
+    bool isTabItem() const { return roleValue() == AccessibilityRole::Tab; }
+    bool isRadioGroup() const { return roleValue() == AccessibilityRole::RadioGroup; }
+    bool isComboBox() const { return roleValue() == AccessibilityRole::ComboBox; }
+    bool isTree() const { return roleValue() == AccessibilityRole::Tree; }
+    bool isTreeGrid() const { return roleValue() == AccessibilityRole::TreeGrid; }
+    bool isTreeItem() const { return roleValue() == AccessibilityRole::TreeItem; }
+    bool isScrollbar() const { return roleValue() == AccessibilityRole::ScrollBar; }
     virtual bool isButton() const = 0;
-    virtual bool isListItem() const = 0;
-    virtual bool isCheckboxOrRadio() const = 0;
-    virtual bool isScrollView() const = 0;
-    virtual bool isCanvas() const = 0;
-    virtual bool isPopUpButton() const = 0;
+
+    bool isListItem() const { return roleValue() == AccessibilityRole::ListItem; }
+    bool isCheckboxOrRadio() const { return isCheckbox() || isRadioButton(); }
+    bool isScrollView() const { return roleValue() == AccessibilityRole::ScrollArea; }
+    bool isCanvas() const { return roleValue() == AccessibilityRole::Canvas; }
+    bool isPopUpButton() const { return roleValue() == AccessibilityRole::PopUpButton; }
+    bool isColorWell() const { return roleValue() == AccessibilityRole::ColorWell; }
+    bool isSplitter() const { return roleValue() == AccessibilityRole::Splitter; }
+    bool isToolbar() const { return roleValue() == AccessibilityRole::Toolbar; }
+    bool isSummary() const { return roleValue() == AccessibilityRole::Summary; }
+
     virtual bool isBlockquote() const = 0;
     virtual bool isLandmark() const = 0;
-    virtual bool isColorWell() const = 0;
     virtual bool isRangeControl() const = 0;
     virtual bool isMeter() const = 0;
-    virtual bool isSplitter() const = 0;
-    virtual bool isToolbar() const = 0;
     virtual bool isStyleFormatGroup() const = 0;
     virtual bool isFigureElement() const = 0;
     virtual bool isKeyboardFocusable() const = 0;
-    virtual bool isSummary() const = 0;
     virtual bool isOutput() const = 0;
 
     virtual bool isChecked() const = 0;
@@ -599,7 +614,7 @@ public:
     virtual bool hasHighlighting() const = 0;
 
     virtual bool supportsDatetimeAttribute() const = 0;
-    virtual const AtomString& datetimeAttributeValue() const = 0;
+    virtual String datetimeAttributeValue() const = 0;
 
     virtual bool canSetFocusAttribute() const = 0;
     virtual bool canSetTextRangeAttributes() const = 0;
@@ -666,8 +681,8 @@ public:
     virtual AccessibilitySortDirection sortDirection() const = 0;
     virtual bool canvasHasFallbackContent() const = 0;
     virtual bool supportsRangeValue() const = 0;
-    virtual const AtomString& identifierAttribute() const = 0;
-    virtual const AtomString& linkRelValue() const = 0;
+    virtual String identifierAttribute() const = 0;
+    virtual String linkRelValue() const = 0;
     virtual void classList(Vector<String>&) const = 0;
     virtual AccessibilityCurrentState currentState() const = 0;
     virtual String currentValue() const = 0;
@@ -791,8 +806,8 @@ public:
     virtual URL url() const = 0;
     virtual VisibleSelection selection() const = 0;
     virtual String selectedText() const = 0;
-    virtual const AtomString& accessKey() const = 0;
-    virtual const String& actionVerb() const = 0;
+    virtual String accessKey() const = 0;
+    virtual String actionVerb() const = 0;
     virtual Widget* widget() const = 0;
     virtual Widget* widgetForAttachmentView() const = 0;
     virtual Page* page() const = 0;
@@ -805,7 +820,8 @@ public:
     virtual String language() const = 0;
     // 1-based, to match the aria-level spec.
     virtual unsigned hierarchicalLevel() const = 0;
-
+    virtual bool isInlineText() const = 0;
+    
     virtual void setFocused(bool) = 0;
     virtual void setSelectedText(const String&) = 0;
     virtual void setSelectedTextRange(const PlainTextRange&) = 0;
@@ -860,6 +876,7 @@ public:
     virtual bool hasAttribute(const QualifiedName&) const = 0;
     virtual const AtomString& getAttribute(const QualifiedName&) const = 0;
     virtual bool hasTagName(const QualifiedName&) const = 0;
+    virtual String tagName() const = 0;
 
     virtual VisiblePositionRange visiblePositionRange() const = 0;
     virtual VisiblePositionRange visiblePositionRangeForLine(unsigned) const = 0;
@@ -930,6 +947,7 @@ public:
     virtual bool isValueAutofilled() const = 0;
     virtual bool isValueAutofillAvailable() const = 0;
     virtual AutoFillButtonType valueAutofillButtonType() const = 0;
+    virtual bool hasARIAValueNow() const = 0;
 
     // Used by an ARIA tree to get all its rows.
     virtual void ariaTreeRows(AccessibilityChildrenVector&) = 0;
@@ -1027,7 +1045,8 @@ public:
     virtual bool isAnonymousMathOperator() const = 0;
 
     // Multiscripts components.
-    typedef Vector<std::pair<AXCoreObject*, AXCoreObject*>> AccessibilityMathMultiscriptPairs;
+    typedef std::pair<AXCoreObject*, AXCoreObject*> AccessibilityMathMultiscriptPair;
+    typedef Vector<AccessibilityMathMultiscriptPair> AccessibilityMathMultiscriptPairs;
     virtual void mathPrescripts(AccessibilityMathMultiscriptPairs&) = 0;
     virtual void mathPostscripts(AccessibilityMathMultiscriptPairs&) = 0;
 
@@ -1064,6 +1083,7 @@ public:
     virtual String descriptionAttributeValue() const = 0;
     virtual String helpTextAttributeValue() const = 0;
     virtual String titleAttributeValue() const = 0;
+    virtual bool hasApplePDFAnnotationAttribute() const = 0;
 #endif
 
 #if PLATFORM(COCOA) && !PLATFORM(IOS_FAMILY)
@@ -1080,6 +1100,10 @@ public:
     virtual void setIsIgnoredFromParentData(AccessibilityIsIgnoredFromParentData&) = 0;
     virtual void clearIsIgnoredFromParentData() = 0;
     virtual void setIsIgnoredFromParentDataForChild(AXCoreObject*) = 0;
+    
+    virtual uint64_t sessionID() const = 0;
+    virtual String documentURI() const = 0;
+    virtual String documentEncoding() const = 0;
 };
 
 namespace Accessibility {
index 89496bd..b7da6aa 100644 (file)
@@ -1570,7 +1570,7 @@ String AccessibilityRenderObject::selectedText() const
     return doAXStringForRange(documentBasedSelectedTextRange());
 }
 
-const AtomString& AccessibilityRenderObject::accessKey() const
+String AccessibilityRenderObject::accessKey() const
 {
     Node* node = m_renderer->node();
     if (!is<Element>(node))
@@ -3582,7 +3582,7 @@ void AccessibilityRenderObject::tabChildren(AccessibilityChildrenVector& result)
     }
 }
     
-const String& AccessibilityRenderObject::actionVerb() const
+String AccessibilityRenderObject::actionVerb() const
 {
 #if !PLATFORM(IOS_FAMILY)
     // FIXME: Need to add verbs for select elements.
index 3961730..3f34678 100644 (file)
@@ -134,8 +134,8 @@ public:
     String text() const override;
     int textLength() const override;
     String selectedText() const override;
-    const AtomString& accessKey() const override;
-    const String& actionVerb() const override;
+    String accessKey() const override;
+    String actionVerb() const override;
     Widget* widget() const override;
     Widget* widgetForAttachmentView() const override;
     virtual void getDocumentLinks(AccessibilityChildrenVector&);
index 00e90a2..1a2dc96 100644 (file)
@@ -46,7 +46,6 @@ private:
     AccessibilitySpinButton();
 
     AccessibilityRole roleValue() const override { return AccessibilityRole::SpinButton; }
-    bool isSpinButton() const override { return true; }
     bool isNativeSpinButton() const override { return true; }
     void addChildren() override;
     LayoutRect elementRect() const override;
index b0f73e6..a461c1f 100644 (file)
@@ -98,7 +98,7 @@ static const gchar* webkitAccessibleHyperlinkActionGetKeybinding(AtkAction* acti
         return nullptr;
 
     auto& coreObject = webkitAccessibleGetAccessibilityObject(accessibleHyperlink->priv->hyperlinkImpl);
-    accessibleHyperlink->priv->actionKeyBinding = coreObject.accessKey().string().utf8();
+    accessibleHyperlink->priv->actionKeyBinding = coreObject.accessKey().utf8();
     return accessibleHyperlink->priv->actionKeyBinding.data();
 }
 
index 581759b..ca23adf 100644 (file)
@@ -83,7 +83,7 @@ static const gchar* webkitAccessibleActionGetKeybinding(AtkAction* action, gint)
     returnValIfWebKitAccessibleIsInvalid(accessible, nullptr);
 
     // FIXME: Construct a proper keybinding string.
-    return webkitAccessibleCacheAndReturnAtkProperty(accessible, AtkCachedActionKeyBinding, core(action)->accessKey().string().utf8());
+    return webkitAccessibleCacheAndReturnAtkProperty(accessible, AtkCachedActionKeyBinding, core(action)->accessKey().utf8());
 }
 
 static const gchar* webkitAccessibleActionGetName(AtkAction* action, gint)
index 5d3fcba..3c3918a 100644 (file)
@@ -115,7 +115,7 @@ RefPtr<AXIsolatedObject> AXIsolatedTree::rootNode()
     return nodeForID(m_rootNodeID);
 }
 
-void AXIsolatedTree::setRoot(Ref<AXIsolatedObject>& root)
+void AXIsolatedTree::setRootNode(Ref<AXIsolatedObject>& root)
 {
     LockHolder locker { m_changeLogLock };
     m_rootNodeID = root->objectID();
index 307cd91..9efb22b 100644 (file)
@@ -57,7 +57,7 @@ public:
     void appendNodeChanges(Vector<Ref<AXIsolatedObject>>&);
     void removeNode(AXID);
 
-    void setRoot(Ref<AXIsolatedObject>&);
+    void setRootNode(Ref<AXIsolatedObject>&);
     void setFocusedNodeID(AXID);
     
     // Call on AX thread
index 8704f94..71e5dc2 100644 (file)
 
 namespace WebCore {
 
-AXIsolatedObject::AXIsolatedObject(AXCoreObject& object)
+AXIsolatedObject::AXIsolatedObject(AXCoreObject& object, bool isRoot)
     : m_id(object.objectID())
 {
     ASSERT(isMainThread());
-    initializeAttributeData(object);
+    initializeAttributeData(object, isRoot);
 #if !ASSERT_DISABLED
     m_initialized = true;
 #endif
 }
 
-Ref<AXIsolatedObject> AXIsolatedObject::create(AXCoreObject& object)
+Ref<AXIsolatedObject> AXIsolatedObject::create(AXCoreObject& object, bool isRoot)
 {
-    return adoptRef(*new AXIsolatedObject(object));
+    return adoptRef(*new AXIsolatedObject(object, isRoot));
 }
 
 AXIsolatedObject::~AXIsolatedObject() = default;
 
-void AXIsolatedObject::initializeAttributeData(AXCoreObject& object)
+void AXIsolatedObject::initializeAttributeData(AXCoreObject& object, bool isRoot)
 {
     setProperty(AXPropertyName::BoundingBoxRect, object.boundingBoxRect());
     setProperty(AXPropertyName::ElementRect, object.elementRect());
@@ -58,7 +58,6 @@ void AXIsolatedObject::initializeAttributeData(AXCoreObject& object)
     setProperty(AXPropertyName::ARIALandmarkRoleDescription, object.ariaLandmarkRoleDescription().isolatedCopy());
     setProperty(AXPropertyName::RoleDescription, object.roleDescription().isolatedCopy());
     setProperty(AXPropertyName::IsAttachment, object.isAttachment());
-    setProperty(AXPropertyName::IsMediaControlLabel, object.isMediaControlLabel());
     setProperty(AXPropertyName::IsLink, object.isLink());
     setProperty(AXPropertyName::IsImageMapLink, object.isImageMapLink());
     setProperty(AXPropertyName::IsImage, object.isImage());
@@ -71,7 +70,41 @@ void AXIsolatedObject::initializeAttributeData(AXCoreObject& object)
     setProperty(AXPropertyName::Title, object.titleAttributeValue().isolatedCopy());
     setProperty(AXPropertyName::Description, object.descriptionAttributeValue().isolatedCopy());
     setProperty(AXPropertyName::HelpText, object.helpTextAttributeValue().isolatedCopy());
-
+    setProperty(AXPropertyName::IsSearchField, object.isSearchField());
+    setProperty(AXPropertyName::IsMediaTimeline, object.isMediaTimeline());
+    setProperty(AXPropertyName::IsMenuRelated, object.isMenuRelated());
+    setProperty(AXPropertyName::IsMenu, object.isMenu());
+    setProperty(AXPropertyName::IsMenuBar, object.isMenuBar());
+    setProperty(AXPropertyName::IsMenuButton, object.isMenuButton());
+    setProperty(AXPropertyName::IsMenuItem, object.isMenuItem());
+    setProperty(AXPropertyName::IsInputImage, object.isInputImage());
+    setProperty(AXPropertyName::IsProgressIndicator, object.isProgressIndicator());
+    setProperty(AXPropertyName::IsSlider, object.isSlider());
+    setProperty(AXPropertyName::IsControl, object.isControl());
+    setProperty(AXPropertyName::IsList, object.isList());
+    setProperty(AXPropertyName::IsTable, object.isTable());
+    setProperty(AXPropertyName::IsTableRow, object.isTableRow());
+    setProperty(AXPropertyName::IsTableColumn, object.isTableColumn());
+    setProperty(AXPropertyName::IsTableCell, object.isTableCell());
+    setProperty(AXPropertyName::IsFieldset, object.isFieldset());
+    setProperty(AXPropertyName::IsGroup, object.isGroup());
+    setProperty(AXPropertyName::IsARIATreeGridRow, object.isARIATreeGridRow());
+    setProperty(AXPropertyName::IsMenuList, object.isMenuList());
+    setProperty(AXPropertyName::IsMenuListPopup, object.isMenuListPopup());
+    setProperty(AXPropertyName::IsMenuListOption, object.isMenuListOption());
+    setProperty(AXPropertyName::IsTextControl, object.isTextControl());
+    setProperty(AXPropertyName::IsButton, object.isButton());
+    setProperty(AXPropertyName::IsRangeControl, object.isRangeControl());
+    setProperty(AXPropertyName::IsStyleFormatGroup, object.isStyleFormatGroup());
+    setProperty(AXPropertyName::IsOutput, object.isOutput());
+    setProperty(AXPropertyName::SupportsDatetimeAttribute, object.supportsDatetimeAttribute());
+    setProperty(AXPropertyName::DatetimeAttributeValue, object.datetimeAttributeValue());
+    setProperty(AXPropertyName::CanSetFocusAttribute, object.canSetFocusAttribute());
+    setProperty(AXPropertyName::CanSetTextRangeAttributes, object.canSetTextRangeAttributes());
+    setProperty(AXPropertyName::CanSetValueAttribute, object.canSetValueAttribute());
+    setProperty(AXPropertyName::CanSetNumericValue, object.canSetNumericValue());
+    setProperty(AXPropertyName::IsPasswordField, object.isPasswordField());
+    setProperty(AXPropertyName::IsHeading, object.isHeading());
     setProperty(AXPropertyName::IsChecked, object.isChecked());
     setProperty(AXPropertyName::IsEnabled, object.isEnabled());
     setProperty(AXPropertyName::IsSelected, object.isSelected());
@@ -92,7 +125,164 @@ void AXIsolatedObject::initializeAttributeData(AXCoreObject& object)
     setProperty(AXPropertyName::IsVisible, object.isVisible());
     setProperty(AXPropertyName::IsCollapsed, object.isCollapsed());
     setProperty(AXPropertyName::IsSelectedOptionActive, object.isSelectedOptionActive());
+    setProperty(AXPropertyName::CanSetSelectedAttribute, object.canSetSelectedAttribute());
+    setProperty(AXPropertyName::CanSetSelectedChildrenAttribute, object.canSetSelectedChildrenAttribute());
+    setProperty(AXPropertyName::CanSetExpandedAttribute, object.canSetExpandedAttribute());
+    setProperty(AXPropertyName::IsShowingValidationMessage, object.isShowingValidationMessage());
+    setProperty(AXPropertyName::ValidationMessage, object.validationMessage());
+    setProperty(AXPropertyName::BlockquoteLevel, object.blockquoteLevel());
+    setProperty(AXPropertyName::HeadingLevel, object.headingLevel());
+    setProperty(AXPropertyName::TableLevel, object.tableLevel());
+    setProperty(AXPropertyName::AccessibilityButtonState, static_cast<int>(object.checkboxOrRadioValue()));
+    setProperty(AXPropertyName::ValueDescription, object.valueDescription());
+    setProperty(AXPropertyName::ValueForRange, object.valueForRange());
+    setProperty(AXPropertyName::MaxValueForRange, object.maxValueForRange());
+    setProperty(AXPropertyName::MinValueForRange, object.minValueForRange());
+    setProperty(AXPropertyName::SelectedRadioButton, object.selectedRadioButton());
+    setProperty(AXPropertyName::SelectedTabItem, object.selectedTabItem());
+    setProperty(AXPropertyName::LayoutCount, object.layoutCount());
+    setProperty(AXPropertyName::EstimatedLoadingProgress, object.estimatedLoadingProgress());
+    setProperty(AXPropertyName::SupportsARIAOwns, object.supportsARIAOwns());
+    setProperty(AXPropertyName::IsActiveDescendantOfFocusedContainer, object.isActiveDescendantOfFocusedContainer());
+    setProperty(AXPropertyName::HasPopup, object.hasPopup());
+    setProperty(AXPropertyName::PopupValue, object.popupValue());
+    setProperty(AXPropertyName::PressedIsPresent, object.pressedIsPresent());
+    setProperty(AXPropertyName::ARIAIsMultiline, object.ariaIsMultiline());
+    setProperty(AXPropertyName::InvalidStatus, object.invalidStatus());
+    setProperty(AXPropertyName::SupportsExpanded, object.supportsExpanded());
+    setProperty(AXPropertyName::SortDirection, static_cast<int>(object.sortDirection()));
+    setProperty(AXPropertyName::CanvasHasFallbackContent, object.canvasHasFallbackContent());
+    setProperty(AXPropertyName::SupportsRangeValue, object.supportsRangeValue());
+    setProperty(AXPropertyName::IdentifierAttribute, object.identifierAttribute());
+    setProperty(AXPropertyName::LinkRelValue, object.linkRelValue());
+    setProperty(AXPropertyName::CurrentState, static_cast<int>(object.currentState()));
+    setProperty(AXPropertyName::CurrentValue, object.currentValue());
+    setProperty(AXPropertyName::SupportsCurrent, object.supportsCurrent());
+    setProperty(AXPropertyName::KeyShortcutsValue, object.keyShortcutsValue());
+    setProperty(AXPropertyName::SupportsSetSize, object.supportsSetSize());
+    setProperty(AXPropertyName::SupportsPosInSet, object.supportsPosInSet());
+    setProperty(AXPropertyName::SetSize, object.setSize());
+    setProperty(AXPropertyName::PosInSet, object.posInSet());
+    setProperty(AXPropertyName::SupportsARIADropping, object.supportsARIADropping());
+    setProperty(AXPropertyName::SupportsARIADragging, object.supportsARIADragging());
+    setProperty(AXPropertyName::IsARIAGrabbed, object.isARIAGrabbed());
+    setProperty(AXPropertyName::ARIADropEffects, object.determineARIADropEffects());
+    setObjectProperty(AXPropertyName::TitleUIElement, object.titleUIElement());
+    setProperty(AXPropertyName::ExposesTitleUIElement, object.exposesTitleUIElement());
+    setObjectProperty(AXPropertyName::VerticalScrollBar, object.scrollBar(AccessibilityOrientation::Vertical));
+    setObjectProperty(AXPropertyName::HorizontalScrollBar, object.scrollBar(AccessibilityOrientation::Horizontal));
+    setProperty(AXPropertyName::ARIARoleAttribute, static_cast<int>(object.ariaRoleAttribute()));
+    setProperty(AXPropertyName::ComputedLabel, object.computedLabel());
+    setProperty(AXPropertyName::PlaceholderValue, object.placeholderValue());
+    setProperty(AXPropertyName::ExpandedTextValue, object.expandedTextValue());
+    setProperty(AXPropertyName::SupportsExpandedTextValue, object.supportsExpandedTextValue());
+    setProperty(AXPropertyName::SupportsPressAction, object.supportsPressAction());
+    setProperty(AXPropertyName::ClickPoint, object.clickPoint());
+    setProperty(AXPropertyName::ComputedRoleString, object.computedRoleString());
+    setProperty(AXPropertyName::IsValueAutofilled, object.isValueAutofilled());
+    setProperty(AXPropertyName::IsValueAutofillAvailable, object.isValueAutofillAvailable());
+    setProperty(AXPropertyName::ValueAutofillButtonType, static_cast<int>(object.valueAutofillButtonType()));
+    setProperty(AXPropertyName::URL, object.url());
+    setProperty(AXPropertyName::AccessKey, object.accessKey());
+    setProperty(AXPropertyName::ActionVerb, object.actionVerb());
+    setProperty(AXPropertyName::ReadOnlyValue, object.readOnlyValue());
+    setProperty(AXPropertyName::AutoCompleteValue, object.autoCompleteValue());
+    setProperty(AXPropertyName::SpeakAs, object.speakAsProperty());
+    setProperty(AXPropertyName::CaretBrowsingEnabled, object.caretBrowsingEnabled());
+    setObjectProperty(AXPropertyName::FocusableAncestor, object.focusableAncestor());
+    setObjectProperty(AXPropertyName::EditableAncestor, object.editableAncestor());
+    setObjectProperty(AXPropertyName::HighestEditableAncestor, object.highestEditableAncestor());
+    setProperty(AXPropertyName::Orientation, static_cast<int>(object.orientation()));
+    setProperty(AXPropertyName::HierarchicalLevel, object.hierarchicalLevel());
+    setProperty(AXPropertyName::Language, object.language());
+    setProperty(AXPropertyName::CanHaveSelectedChildren, object.canHaveSelectedChildren());
+    setProperty(AXPropertyName::HasARIAValueNow, object.hasARIAValueNow());
+    setProperty(AXPropertyName::TagName, object.tagName());
+    setProperty(AXPropertyName::SupportsLiveRegion, object.supportsLiveRegion());
+    setProperty(AXPropertyName::IsInsideLiveRegion, object.isInsideLiveRegion());
+    setProperty(AXPropertyName::LiveRegionStatus, object.liveRegionStatus());
+    setProperty(AXPropertyName::LiveRegionRelevant, object.liveRegionRelevant());
+    setProperty(AXPropertyName::LiveRegionAtomic, object.liveRegionAtomic());
+    setProperty(AXPropertyName::IsBusy, object.isBusy());
+    setProperty(AXPropertyName::IsInlineText, object.isInlineText());
+    if (object.isTextControl())
+        setProperty(AXPropertyName::TextLength, object.textLength());
+
+    AccessibilityChildrenVector selectedChildren;
+    object.selectedChildren(selectedChildren);
+    setObjectVectorProperty(AXPropertyName::SelectedChildren, selectedChildren);
+
+    AccessibilityChildrenVector visibleChildren;
+    object.visibleChildren(visibleChildren);
+    setObjectVectorProperty(AXPropertyName::VisibleChildren, visibleChildren);
+
+    AccessibilityChildrenVector tabChildren;
+    object.tabChildren(tabChildren);
+    setObjectVectorProperty(AXPropertyName::TabChildren, tabChildren);
+
+    AccessibilityChildrenVector ariaTreeRows;
+    object.ariaTreeRows(ariaTreeRows);
+    setObjectVectorProperty(AXPropertyName::ARIATreeRows, ariaTreeRows);
+
+    AccessibilityChildrenVector ariaTreeItemDisclosedRows;
+    object.ariaTreeItemDisclosedRows(ariaTreeItemDisclosedRows);
+    setObjectVectorProperty(AXPropertyName::ARIATreeItemDisclosedRows, ariaTreeItemDisclosedRows);
+
+    AccessibilityChildrenVector ariaTreeItemContent;
+    object.ariaTreeItemContent(ariaTreeItemContent);
+    setObjectVectorProperty(AXPropertyName::ARIATreeItemContent, ariaTreeItemContent);
+
+    AccessibilityChildrenVector linkedUIElements;
+    object.linkedUIElements(linkedUIElements);
+    setObjectVectorProperty(AXPropertyName::LinkedUIElements, linkedUIElements);
 
+    AccessibilityChildrenVector ariaControlsElements;
+    object.ariaControlsElements(ariaControlsElements);
+    setObjectVectorProperty(AXPropertyName::ARIAControlsElements, ariaControlsElements);
+
+    AccessibilityChildrenVector ariaDetailsElements;
+    object.ariaDetailsElements(ariaDetailsElements);
+    setObjectVectorProperty(AXPropertyName::ARIADetailsElements, ariaDetailsElements);
+
+    AccessibilityChildrenVector ariaErrorMessageElements;
+    object.ariaErrorMessageElements(ariaErrorMessageElements);
+    setObjectVectorProperty(AXPropertyName::ARIAErrorMessageElements, ariaErrorMessageElements);
+
+    AccessibilityChildrenVector ariaFlowToElements;
+    object.ariaFlowToElements(ariaFlowToElements);
+    setObjectVectorProperty(AXPropertyName::ARIAFlowToElements, ariaFlowToElements);
+
+    AccessibilityChildrenVector ariaOwnsElements;
+    object.ariaOwnsElements(ariaOwnsElements);
+    setObjectVectorProperty(AXPropertyName::ARIAOwnsElements, ariaOwnsElements);
+
+    Vector<AccessibilityText> texts;
+    object.accessibilityText(texts);
+    Vector<AccessibilityIsolatedTreeText> isolatedTexts;
+    isolatedTexts.reserveCapacity(texts.size());
+    for (auto text : texts) {
+        AccessibilityIsolatedTreeText isolatedText;
+        isolatedText.text = text.text;
+        isolatedText.textSource = text.textSource;
+        for (auto object : text.textElements)
+            isolatedText.textElements.append(object->objectID());
+        isolatedTexts.uncheckedAppend(isolatedText);
+    }
+    setProperty(AXPropertyName::AccessibilityText, isolatedTexts);
+
+    Vector<String> classList;
+    object.classList(classList);
+    String combinedClassList;
+    for (auto it = classList.begin(), end = classList.end(); it != end; ++it) {
+        combinedClassList.append(*it);
+        combinedClassList.append(" ");
+    }
+    setProperty(AXPropertyName::ClassList, combinedClassList);
+    
+    int r, g, b;
+    object.colorValue(r, g, b);
+    setProperty(AXPropertyName::ColorValue, Color(r, g, b));
+    
     if (bool isMathElement = object.isMathElement()) {
         setProperty(AXPropertyName::IsMathElement, isMathElement);
         setProperty(AXPropertyName::IsAnonymousMathOperator, object.isAnonymousMathOperator());
@@ -126,7 +316,41 @@ void AXIsolatedObject::initializeAttributeData(AXCoreObject& object)
         setObjectProperty(AXPropertyName::MathBaseObject, object.mathBaseObject());
         setObjectProperty(AXPropertyName::MathSubscriptObject, object.mathSubscriptObject());
         setObjectProperty(AXPropertyName::MathSuperscriptObject, object.mathSuperscriptObject());
+        setMathscripts(AXPropertyName::MathPrescripts, object);
+        setMathscripts(AXPropertyName::MathPostscripts, object);
+    }
+    
+    if (isRoot) {
+        setProperty(AXPropertyName::PreventKeyboardDOMEventDispatch, object.preventKeyboardDOMEventDispatch());
+        setProperty(AXPropertyName::SessionID, object.sessionID());
+        setProperty(AXPropertyName::DocumentURI, object.documentURI());
+        setProperty(AXPropertyName::DocumentEncoding, object.documentEncoding());
+    }
+}
+
+void AXIsolatedObject::setMathscripts(AXPropertyName propertyName, AXCoreObject& object)
+{
+    AccessibilityMathMultiscriptPairs pairs;
+    if (propertyName == AXPropertyName::MathPrescripts)
+        object.mathPrescripts(pairs);
+    else if (propertyName == AXPropertyName::MathPostscripts)
+        object.mathPostscripts(pairs);
+    
+    size_t mathSize = pairs.size();
+    if (!mathSize)
+        return;
+    
+    Vector<AccessibilityIsolatedTreeMathMultiscriptPair> idPairs;
+    idPairs.reserveCapacity(mathSize);
+    for (auto mathPair : pairs) {
+        AccessibilityIsolatedTreeMathMultiscriptPair idPair;
+        if (mathPair.first)
+            idPair.first = mathPair.first->objectID();
+        if (mathPair.second)
+            idPair.second = mathPair.second->objectID();
+        idPairs.uncheckedAppend(idPair);
     }
+    setProperty(propertyName, idPairs);
 }
 
 void AXIsolatedObject::setObjectProperty(AXPropertyName propertyName, AXCoreObject* object)
@@ -137,6 +361,19 @@ void AXIsolatedObject::setObjectProperty(AXPropertyName propertyName, AXCoreObje
         setProperty(propertyName, nullptr, true);
 }
 
+void AXIsolatedObject::setObjectVectorProperty(AXPropertyName propertyName, AccessibilityChildrenVector& children)
+{
+    size_t childrenSize = children.size();
+    if (!childrenSize)
+        return;
+    
+    Vector<AXID> childrenVector;
+    childrenVector.reserveCapacity(childrenSize);
+    for (auto childObject : children)
+        childrenVector.uncheckedAppend(childObject->objectID());
+    setProperty(propertyName, childrenVector);
+}
+
 void AXIsolatedObject::setProperty(AXPropertyName propertyName, AttributeValueVariant&& value, bool shouldRemove)
 {
     ASSERT(!m_initialized);
@@ -160,6 +397,12 @@ void AXIsolatedObject::setParent(AXID parent)
     m_parent = parent;
 }
 
+bool AXIsolatedObject::isDetached() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
 void AXIsolatedObject::setTreeIdentifier(AXIsolatedTreeID treeIdentifier)
 {
     m_treeIdentifier = treeIdentifier;
@@ -180,6 +423,83 @@ const AXCoreObject::AccessibilityChildrenVector& AXIsolatedObject::children(bool
     return m_children;
 }
 
+bool AXIsolatedObject::isDetachedFromParent()
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+void AXIsolatedObject::accessibilityText(Vector<AccessibilityText>& texts) const
+{
+    auto isolatedTexts = vectorAttributeValue<AccessibilityIsolatedTreeText>(AXPropertyName::AccessibilityText);
+    for (auto isolatedText : isolatedTexts) {
+        AccessibilityText text(isolatedText.text, isolatedText.textSource);
+        for (auto axID : isolatedText.textElements) {
+            if (auto object = tree()->nodeForID(axID))
+                text.textElements.append(object);
+        }
+        texts.append(text);
+    }
+}
+
+void AXIsolatedObject::classList(Vector<String>& list) const
+{
+    String classList = stringAttributeValue(AXPropertyName::ClassList);
+    list.appendVector(classList.split(" "));
+}
+
+uint64_t AXIsolatedObject::sessionID() const
+{
+    if (auto root = tree()->rootNode())
+        return root->uint64AttributeValue(AXPropertyName::SessionID);
+    return 0;
+}
+
+String AXIsolatedObject::documentURI() const
+{
+    if (auto root = tree()->rootNode())
+        return root->stringAttributeValue(AXPropertyName::DocumentURI);
+    return String();
+}
+
+bool AXIsolatedObject::preventKeyboardDOMEventDispatch() const
+{
+    if (auto root = tree()->rootNode())
+        return root->boolAttributeValue(AXPropertyName::PreventKeyboardDOMEventDispatch);
+    return false;
+}
+
+String AXIsolatedObject::documentEncoding() const
+{
+    if (auto root = tree()->rootNode())
+        return root->stringAttributeValue(AXPropertyName::DocumentEncoding);
+    return String();
+}
+
+void AXIsolatedObject::insertMathPairs(Vector<AccessibilityIsolatedTreeMathMultiscriptPair>& isolatedPairs, AccessibilityMathMultiscriptPairs& pairs)
+{
+    for (auto pair : isolatedPairs) {
+        AccessibilityMathMultiscriptPair prescriptPair;
+        if (auto* coreObject = tree()->nodeForID(pair.first).get())
+            prescriptPair.first = coreObject;
+        if (auto* coreObject = tree()->nodeForID(pair.second).get())
+            prescriptPair.second = coreObject;
+        pairs.append(prescriptPair);
+    }
+}
+
+void AXIsolatedObject::mathPrescripts(AccessibilityMathMultiscriptPairs& pairs)
+{
+    auto isolatedPairs = vectorAttributeValue<AccessibilityIsolatedTreeMathMultiscriptPair>(AXPropertyName::MathPrescripts);
+    insertMathPairs(isolatedPairs, pairs);
+}
+
+void AXIsolatedObject::mathPostscripts(AccessibilityMathMultiscriptPairs& pairs)
+{
+    auto isolatedPairs = vectorAttributeValue<AccessibilityIsolatedTreeMathMultiscriptPair>(AXPropertyName::MathPostscripts);
+    insertMathPairs(isolatedPairs, pairs);
+}
+
 AXCoreObject* AXIsolatedObject::focusedUIElement() const
 {
     if (auto focusedElement = tree()->focusedUIElement())
@@ -192,6 +512,19 @@ AXCoreObject* AXIsolatedObject::parentObjectUnignored() const
     return tree()->nodeForID(parent()).get();
 }
 
+AXCoreObject* AXIsolatedObject::scrollBar(AccessibilityOrientation orientation)
+{
+    return objectAttributeValue(orientation == AccessibilityOrientation::Vertical ? AXPropertyName::VerticalScrollBar : AXPropertyName::HorizontalScrollBar);
+}
+
+void AXIsolatedObject::colorValue(int& r, int& g, int& b) const
+{
+    auto color = colorAttributeValue(AXPropertyName::ColorValue);
+    r = color.red();
+    g = color.green();
+    b = color.blue();
+}
+
 AXCoreObject* AXIsolatedObject::accessibilityHitTest(const IntPoint& point) const
 {
     if (!relativeFrame().contains(point))
@@ -210,6 +543,15 @@ AXIsolatedTree* AXIsolatedObject::tree() const
     return m_cachedTree.get();
 }
 
+IntPoint AXIsolatedObject::intPointAttributeValue(AXPropertyName propertyName) const
+{
+    auto value = m_attributeMap.get(propertyName);
+    return WTF::switchOn(value,
+        [] (IntPoint& typedValue) { return typedValue; },
+        [] (auto&) { return IntPoint(); }
+    );
+}
+
 AXCoreObject* AXIsolatedObject::objectAttributeValue(AXPropertyName propertyName) const
 {
     auto value = m_attributeMap.get(propertyName);
@@ -231,6 +573,62 @@ T AXIsolatedObject::rectAttributeValue(AXPropertyName propertyName) const
     );
 }
 
+template<typename T>
+Vector<T> AXIsolatedObject::vectorAttributeValue(AXPropertyName propertyName) const
+{
+    auto value = m_attributeMap.get(propertyName);
+    return WTF::switchOn(value,
+        [] (Vector<T>& typedValue) { return typedValue; },
+        [] (auto&) { return Vector<T>(); }
+    );
+}
+
+template<typename T>
+OptionSet<T> AXIsolatedObject::optionSetAttributeValue(AXPropertyName propertyName) const
+{
+    auto value = m_attributeMap.get(propertyName);
+    return WTF::switchOn(value,
+        [] (T& typedValue) { return typedValue; },
+        [] (auto&) { return OptionSet<T>(); }
+    );
+}
+
+uint64_t AXIsolatedObject::uint64AttributeValue(AXPropertyName propertyName) const
+{
+    auto value = m_attributeMap.get(propertyName);
+    return WTF::switchOn(value,
+        [] (uint64_t& typedValue) { return typedValue; },
+        [] (auto&) { return 0; }
+    );
+}
+
+URL AXIsolatedObject::urlAttributeValue(AXPropertyName propertyName) const
+{
+    auto value = m_attributeMap.get(propertyName);
+    return WTF::switchOn(value,
+        [] (URL& typedValue) { return typedValue; },
+        [] (auto&) { return URL(); }
+    );
+}
+
+Color AXIsolatedObject::colorAttributeValue(AXPropertyName propertyName) const
+{
+    auto value = m_attributeMap.get(propertyName);
+    return WTF::switchOn(value,
+        [] (Color& typedValue) { return typedValue; },
+        [] (auto&) { return Color(); }
+    );
+}
+
+float AXIsolatedObject::floatAttributeValue(AXPropertyName propertyName) const
+{
+    auto value = m_attributeMap.get(propertyName);
+    return WTF::switchOn(value,
+        [] (float& typedValue) { return typedValue; },
+        [] (auto&) { return 0; }
+    );
+}
+
 double AXIsolatedObject::doubleAttributeValue(AXPropertyName propertyName) const
 {
     auto value = m_attributeMap.get(propertyName);
@@ -276,6 +674,16 @@ int AXIsolatedObject::intAttributeValue(AXPropertyName propertyName) const
     );
 }
 
+void AXIsolatedObject::fillChildrenVectorForProperty(AXPropertyName propertyName, AccessibilityChildrenVector& children) const
+{
+    Vector<AXID> childIDs = vectorAttributeValue<AXID>(propertyName);
+    children.reserveCapacity(childIDs.size());
+    for (auto childID : childIDs) {
+        if (auto object = tree()->nodeForID(childID))
+            children.uncheckedAppend(object);
+    }
+}
+
 void AXIsolatedObject::updateBackingStore()
 {
     ASSERT(!isMainThread());
@@ -285,6 +693,1049 @@ void AXIsolatedObject::updateBackingStore()
     }
 }
 
+bool AXIsolatedObject::replaceTextInRange(const String&, const PlainTextRange&)
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::insertText(const String&)
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::press()
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::performDefaultAction()
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isAccessibilityObject() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isAccessibilityNodeObject() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isAccessibilityRenderObject() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isAccessibilityScrollbar() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isAccessibilityScrollView() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isAccessibilitySVGRoot() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isAccessibilitySVGElement() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::containsText(String*) const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isAttachmentElement() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isNativeImage() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isImageButton() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isContainedByPasswordField() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+AXCoreObject* AXIsolatedObject::passwordFieldOrContainingPasswordField()
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+bool AXIsolatedObject::isNativeTextControl() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isNativeListBox() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isListBoxOption() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isSliderThumb() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isInputSlider() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isLabel() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isDataTable() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isImageMapLink() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isNativeSpinButton() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isSpinButtonPart() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isMockObject() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isMediaObject() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isARIATextControl() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isNonNativeTextControl() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isBlockquote() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isLandmark() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isFigureElement() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isKeyboardFocusable() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isHovered() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isIndeterminate() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isLoaded() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isOnScreen() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isOffScreen() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isPressed() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isUnvisited() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isLinked() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isVisible() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isCollapsed() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isSelectedOptionActive() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::hasBoldFont() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::hasItalicFont() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::hasMisspelling() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::hasPlainText() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::hasSameFont(RenderObject*) const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::hasSameFontColor(RenderObject*) const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::hasSameStyle(RenderObject*) const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isStaticText() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::hasUnderline() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::hasHighlighting() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+Element* AXIsolatedObject::element() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+Node* AXIsolatedObject::node() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+RenderObject* AXIsolatedObject::renderer() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+AccessibilityObjectInclusion AXIsolatedObject::defaultObjectInclusion() const
+{
+    ASSERT_NOT_REACHED();
+    return AccessibilityObjectInclusion::DefaultBehavior;
+}
+
+bool AXIsolatedObject::accessibilityIsIgnoredByDefault() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+float AXIsolatedObject::stepValueForRange() const
+{
+    ASSERT_NOT_REACHED();
+    return 0;
+}
+
+AXCoreObject* AXIsolatedObject::selectedListItem()
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+void AXIsolatedObject::ariaActiveDescendantReferencingElements(AccessibilityChildrenVector&) const
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::ariaControlsReferencingElements(AccessibilityChildrenVector&) const
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::ariaDescribedByElements(AccessibilityChildrenVector&) const
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::ariaDescribedByReferencingElements(AccessibilityChildrenVector&) const
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::ariaDetailsReferencingElements(AccessibilityChildrenVector&) const
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::ariaErrorMessageReferencingElements(AccessibilityChildrenVector&) const
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::ariaFlowToReferencingElements(AccessibilityChildrenVector&) const
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::ariaLabelledByElements(AccessibilityChildrenVector&) const
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::ariaLabelledByReferencingElements(AccessibilityChildrenVector&) const
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::ariaOwnsReferencingElements(AccessibilityChildrenVector&) const
+{
+    ASSERT_NOT_REACHED();
+}
+
+bool AXIsolatedObject::hasDatalist() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::supportsHasPopup() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::supportsPressed() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::supportsChecked() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::ignoredFromModalPresence() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isModalDescendant(Node*) const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isModalNode() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+AXCoreObject* AXIsolatedObject::elementAccessibilityHitTest(const IntPoint&) const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+AXCoreObject* AXIsolatedObject::firstChild() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+AXCoreObject* AXIsolatedObject::lastChild() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+AXCoreObject* AXIsolatedObject::previousSibling() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+AXCoreObject* AXIsolatedObject::nextSibling() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+AXCoreObject* AXIsolatedObject::nextSiblingUnignored(int) const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+AXCoreObject* AXIsolatedObject::previousSiblingUnignored(int) const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+AXCoreObject* AXIsolatedObject::parentObjectIfExists() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+bool AXIsolatedObject::isDescendantOfBarrenParent() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isDescendantOfRole(AccessibilityRole) const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+AXCoreObject* AXIsolatedObject::observableObject() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+AXCoreObject* AXIsolatedObject::correspondingLabelForControlElement() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+AXCoreObject* AXIsolatedObject::correspondingControlForLabelElement() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+bool AXIsolatedObject::isPresentationalChildOfAriaRole() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::ariaRoleHasPresentationalChildren() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::inheritsPresentationalRole() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+void AXIsolatedObject::setAccessibleName(const AtomString&)
+{
+    ASSERT_NOT_REACHED();
+}
+
+bool AXIsolatedObject::hasAttributesRequiredForInclusion() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+String AXIsolatedObject::accessibilityDescription() const
+{
+    ASSERT_NOT_REACHED();
+    return String();
+}
+
+String AXIsolatedObject::title() const
+{
+    ASSERT_NOT_REACHED();
+    return String();
+}
+
+String AXIsolatedObject::helpText() const
+{
+    ASSERT_NOT_REACHED();
+    return String();
+}
+
+bool AXIsolatedObject::isARIAStaticText() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+String AXIsolatedObject::stringValue() const
+{
+    ASSERT_NOT_REACHED();
+    return String();
+}
+
+String AXIsolatedObject::text() const
+{
+    ASSERT_NOT_REACHED();
+    return String();
+}
+
+String AXIsolatedObject::ariaLabeledByAttribute() const
+{
+    ASSERT_NOT_REACHED();
+    return String();
+}
+
+String AXIsolatedObject::ariaDescribedByAttribute() const
+{
+    ASSERT_NOT_REACHED();
+    return String();
+}
+
+bool AXIsolatedObject::accessibleNameDerivesFromContent() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+void AXIsolatedObject::elementsFromAttribute(Vector<Element*>&, const QualifiedName&) const
+{
+    ASSERT_NOT_REACHED();
+}
+
+AXObjectCache* AXIsolatedObject::axObjectCache() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+Element* AXIsolatedObject::anchorElement() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+Element* AXIsolatedObject::actionElement() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+Path AXIsolatedObject::elementPath() const
+{
+    ASSERT_NOT_REACHED();
+    return Path();
+}
+
+bool AXIsolatedObject::supportsPath() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+TextIteratorBehavior AXIsolatedObject::textIteratorBehaviorForTextRange() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+Widget* AXIsolatedObject::widget() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+Widget* AXIsolatedObject::widgetForAttachmentView() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+Page* AXIsolatedObject::page() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+Document* AXIsolatedObject::document() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+FrameView* AXIsolatedObject::documentFrameView() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+Frame* AXIsolatedObject::frame() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+Frame* AXIsolatedObject::mainFrame() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+Document* AXIsolatedObject::topDocument() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+ScrollView* AXIsolatedObject::scrollViewAncestor() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+void AXIsolatedObject::childrenChanged()
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::textChanged()
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::updateAccessibilityRole()
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::addChildren()
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::addChild(AXCoreObject*)
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::insertChild(AXCoreObject*, unsigned)
+{
+    ASSERT_NOT_REACHED();
+}
+
+bool AXIsolatedObject::shouldIgnoreAttributeRole() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::canHaveChildren() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::hasChildren() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+void AXIsolatedObject::setNeedsToUpdateChildren()
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::setNeedsToUpdateSubtree()
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::clearChildren()
+{
+    ASSERT_NOT_REACHED();
+}
+
+bool AXIsolatedObject::needsToUpdateChildren() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+void AXIsolatedObject::detachFromParent()
+{
+    ASSERT_NOT_REACHED();
+}
+
+bool AXIsolatedObject::shouldFocusActiveDescendant() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+AXCoreObject* AXIsolatedObject::activeDescendant() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+void AXIsolatedObject::handleActiveDescendantChanged()
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::handleAriaExpandedChanged()
+{
+    ASSERT_NOT_REACHED();
+}
+
+bool AXIsolatedObject::isDescendantOfObject(const AXCoreObject*) const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isAncestorOfObject(const AXCoreObject*) const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+AXCoreObject* AXIsolatedObject::firstAnonymousBlockChild() const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+bool AXIsolatedObject::hasAttribute(const QualifiedName&) const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+const AtomString& AXIsolatedObject::getAttribute(const QualifiedName&) const
+{
+    ASSERT_NOT_REACHED();
+    return nullAtom();
+}
+
+bool AXIsolatedObject::hasTagName(const QualifiedName&) const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+String AXIsolatedObject::stringValueForMSAA() const
+{
+    ASSERT_NOT_REACHED();
+    return String();
+}
+
+String AXIsolatedObject::stringRoleForMSAA() const
+{
+    ASSERT_NOT_REACHED();
+    return String();
+}
+
+String AXIsolatedObject::nameForMSAA() const
+{
+    ASSERT_NOT_REACHED();
+    return String();
+}
+
+String AXIsolatedObject::descriptionForMSAA() const
+{
+    ASSERT_NOT_REACHED();
+    return String();
+}
+
+AccessibilityRole AXIsolatedObject::roleValueForMSAA() const
+{
+    ASSERT_NOT_REACHED();
+    return AccessibilityRole::Unknown;
+}
+
+String AXIsolatedObject::passwordFieldValue() const
+{
+    ASSERT_NOT_REACHED();
+    return String();
+}
+
+AXCoreObject* AXIsolatedObject::liveRegionAncestor(bool) const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+bool AXIsolatedObject::hasContentEditableAttributeSet() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::supportsReadOnly() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::supportsAutoComplete() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::supportsARIAAttributes() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::scrollByPage(ScrollByPageDirection) const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+IntPoint AXIsolatedObject::scrollPosition() const
+{
+    ASSERT_NOT_REACHED();
+    return IntPoint();
+}
+
+IntSize AXIsolatedObject::scrollContentsSize() const
+{
+    ASSERT_NOT_REACHED();
+    return IntSize();
+}
+
+IntRect AXIsolatedObject::scrollVisibleContentRect() const
+{
+    ASSERT_NOT_REACHED();
+    return IntRect();
+}
+
+void AXIsolatedObject::scrollToMakeVisible(const ScrollRectToVisibleOptions&) const
+{
+    ASSERT_NOT_REACHED();
+}
+
+bool AXIsolatedObject::lastKnownIsIgnoredValue()
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+void AXIsolatedObject::setLastKnownIsIgnoredValue(bool)
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::notifyIfIgnoredValueChanged()
+{
+    ASSERT_NOT_REACHED();
+}
+
+bool AXIsolatedObject::isMathScriptObject(AccessibilityMathScriptObjectType) const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isMathMultiscriptObject(AccessibilityMathMultiscriptObjectType) const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isAXHidden() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isDOMHidden() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+bool AXIsolatedObject::isHidden() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+void AXIsolatedObject::overrideAttachmentParent(AXCoreObject*)
+{
+    ASSERT_NOT_REACHED();
+}
+
+bool AXIsolatedObject::accessibilityIgnoreAttachment() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+AccessibilityObjectInclusion AXIsolatedObject::accessibilityPlatformIncludesObject() const
+{
+    ASSERT_NOT_REACHED();
+    return AccessibilityObjectInclusion::DefaultBehavior;
+}
+
+bool AXIsolatedObject::hasApplePDFAnnotationAttribute() const
+{
+    ASSERT_NOT_REACHED();
+    return false;
+}
+
+const AccessibilityScrollView* AXIsolatedObject::ancestorAccessibilityScrollView(bool) const
+{
+    ASSERT_NOT_REACHED();
+    return nullptr;
+}
+
+void AXIsolatedObject::setIsIgnoredFromParentData(AccessibilityIsIgnoredFromParentData&)
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::clearIsIgnoredFromParentData()
+{
+    ASSERT_NOT_REACHED();
+}
+
+void AXIsolatedObject::setIsIgnoredFromParentDataForChild(AXCoreObject*)
+{
+    ASSERT_NOT_REACHED();
+}
+
 } // namespace WebCore
 
 #endif // ENABLE((ACCESSIBILITY_ISOLATED_TREE)
index bd75798..9dae2f1 100644 (file)
@@ -47,7 +47,7 @@ class AXIsolatedTree;
 
 class AXIsolatedObject final : public AXCoreObject {
 public:
-    static Ref<AXIsolatedObject> create(AXCoreObject&);
+    static Ref<AXIsolatedObject> create(AXCoreObject&, bool isRoot);
     ~AXIsolatedObject();
 
     void setObjectID(AXID id) override { m_id = id; }
@@ -56,606 +56,110 @@ public:
 
     AccessibilityObjectWrapper* wrapper() const override { return m_wrapper.get(); }
     void detach(AccessibilityDetachmentType, AXObjectCache* = nullptr) override { }
-    bool isDetached() const override { return false; }
+    bool isDetached() const override;
 
     void setTreeIdentifier(AXIsolatedTreeID);
     void setParent(AXID);
     void appendChild(AXID);
 
 private:
-    bool isAccessibilityObject() const override { return false; }
-    bool isAccessibilityNodeObject() const override { return false; }
-    bool isAccessibilityRenderObject() const override { return false; }
-    bool isAccessibilityScrollbar() const override { return false; }
-    bool isAccessibilityScrollView() const override { return false; }
-    bool isAccessibilitySVGRoot() const override { return false; }
-    bool isAccessibilitySVGElement() const override { return false; }
-
-    bool containsText(String *) const override { return false; }
-    bool isAttachmentElement() const override { return false; }
-    bool isHeading() const override { return false; }
-    bool isLink() const override { return boolAttributeValue(AXPropertyName::IsLink); }
-    bool isImage() const override { return boolAttributeValue(AXPropertyName::IsImage); }
-    bool isImageMap() const override { return false; }
-    bool isNativeImage() const override { return false; }
-    bool isImageButton() const override { return false; }
-    bool isPasswordField() const override { return false; }
-    bool isContainedByPasswordField() const override { return false; }
-    AXCoreObject* passwordFieldOrContainingPasswordField() override { return nullptr; }
-    bool isNativeTextControl() const override { return false; }
-    bool isSearchField() const override { return false; }
-    bool isWebArea() const override { return false; }
-    bool isCheckbox() const override { return false; }
-    bool isRadioButton() const override { return false; }
-    bool isNativeListBox() const override { return false; }
-    bool isListBox() const override { return false; }
-    bool isListBoxOption() const override { return false; }
-    bool isAttachment() const override { return boolAttributeValue(AXPropertyName::IsAttachment); }
-    bool isMediaTimeline() const override { return false; }
-    bool isMenuRelated() const override { return false; }
-    bool isMenu() const override { return false; }
-    bool isMenuBar() const override { return false; }
-    bool isMenuButton() const override { return false; }
-    bool isMenuItem() const override { return false; }
-    bool isFileUploadButton() const override { return boolAttributeValue(AXPropertyName::IsFileUploadButton); }
-    bool isInputImage() const override { return false; }
-    bool isProgressIndicator() const override { return false; }
-    bool isSlider() const override { return false; }
-    bool isSliderThumb() const override { return false; }
-    bool isInputSlider() const override { return false; }
-    bool isControl() const override { return false; }
-    bool isLabel() const override { return false; }
-    bool isList() const override { return false; }
-    bool isTable() const override { return false; }
-    bool isDataTable() const override { return false; }
-    bool isTableRow() const override { return false; }
-    bool isTableColumn() const override { return false; }
-    bool isTableCell() const override { return false; }
-    bool isFieldset() const override { return false; }
-    bool isGroup() const override { return false; }
-    bool isARIATreeGridRow() const override { return false; }
-    bool isImageMapLink() const override { return boolAttributeValue(AXPropertyName::IsImageMapLink); }
-    bool isMenuList() const override { return false; }
-    bool isMenuListPopup() const override { return false; }
-    bool isMenuListOption() const override { return false; }
-    bool isSpinButton() const override { return false; }
-    bool isNativeSpinButton() const override { return false; }
-    bool isSpinButtonPart() const override { return false; }
-    bool isMockObject() const override { return false; }
-    bool isMediaControlLabel() const override { return boolAttributeValue(AXPropertyName::IsMediaControlLabel); }
-    bool isMediaObject() const override { return false; }
-    bool isSwitch() const override { return false; }
-    bool isToggleButton() const override { return false; }
-    bool isTextControl() const override { return false; }
-    bool isARIATextControl() const override { return false; }
-    bool isNonNativeTextControl() const override { return false; }
-    bool isTabList() const override { return false; }
-    bool isTabItem() const override { return false; }
-    bool isRadioGroup() const override { return false; }
-    bool isComboBox() const override { return false; }
-    bool isTree() const override { return boolAttributeValue(AXPropertyName::IsTree); }
-    bool isTreeGrid() const override { return false; }
-    bool isTreeItem() const override { return boolAttributeValue(AXPropertyName::IsTreeItem); }
-    bool isScrollbar() const override { return boolAttributeValue(AXPropertyName::IsScrollbar); }
-    bool isButton() const override { return false; }
-    bool isListItem() const override { return false; }
-    bool isCheckboxOrRadio() const override { return false; }
-    bool isScrollView() const override { return false; }
-    bool isCanvas() const override { return false; }
-    bool isPopUpButton() const override { return false; }
-    bool isBlockquote() const override { return false; }
-    bool isLandmark() const override { return false; }
-    bool isColorWell() const override { return false; }
-    bool isRangeControl() const override { return false; }
-    bool isMeter() const override { return false; }
-    bool isSplitter() const override { return false; }
-    bool isToolbar() const override { return false; }
-    bool isStyleFormatGroup() const override { return false; }
-    bool isFigureElement() const override { return false; }
-    bool isKeyboardFocusable() const override { return false; }
-    bool isSummary() const override { return false; }
-    bool isOutput() const override { return false; }
-
-    bool isChecked() const override { return boolAttributeValue(AXPropertyName::IsChecked); }
-    bool isEnabled() const override { return boolAttributeValue(AXPropertyName::IsEnabled); }
-    bool isSelected() const override { return boolAttributeValue(AXPropertyName::IsSelected); }
-    bool isFocused() const override { return boolAttributeValue(AXPropertyName::IsFocused); }
-    bool isHovered() const override { return boolAttributeValue(AXPropertyName::IsHovered); }
-    bool isIndeterminate() const override { return boolAttributeValue(AXPropertyName::IsIndeterminate); }
-    bool isLoaded() const override { return boolAttributeValue(AXPropertyName::IsLoaded); }
-    bool isMultiSelectable() const override { return boolAttributeValue(AXPropertyName::IsMultiSelectable); }
-    bool isOnScreen() const override { return boolAttributeValue(AXPropertyName::IsOnScreen); }
-    bool isOffScreen() const override { return boolAttributeValue(AXPropertyName::IsOffScreen); }
-    bool isPressed() const override { return boolAttributeValue(AXPropertyName::IsPressed); }
-    bool isUnvisited() const override { return boolAttributeValue(AXPropertyName::IsUnvisited); }
-    bool isVisited() const override { return boolAttributeValue(AXPropertyName::IsVisited); }
-    bool isRequired() const override { return boolAttributeValue(AXPropertyName::IsRequired); }
-    bool supportsRequiredAttribute() const override { return boolAttributeValue(AXPropertyName::SupportsRequiredAttribute); }
-    bool isLinked() const override { return boolAttributeValue(AXPropertyName::IsLinked); }
-    bool isExpanded() const override { return boolAttributeValue(AXPropertyName::IsExpanded); }
-    bool isVisible() const override { return boolAttributeValue(AXPropertyName::IsVisible); }
-    bool isCollapsed() const override { return boolAttributeValue(AXPropertyName::IsCollapsed); }
-    FloatRect relativeFrame() const override { return rectAttributeValue<FloatRect>(AXPropertyName::RelativeFrame); }
-    FloatRect convertFrameToSpace(const FloatRect&, AccessibilityConversionSpace) const override { return FloatRect(); }
-
-    bool isSelectedOptionActive() const override { return boolAttributeValue(AXPropertyName::IsSelectedOptionActive); }
-
-    void setIsExpanded(bool) override { }
-    bool hasBoldFont() const override { return false; }
-    bool hasItalicFont() const override { return false; }
-    bool hasMisspelling() const override { return false; }
-    RefPtr<Range> getMisspellingRange(RefPtr<Range> const&, AccessibilitySearchDirection) const override { return nullptr; }
-    bool hasPlainText() const override { return false; }
-    bool hasSameFont(RenderObject*) const override { return false; }
-    bool hasSameFontColor(RenderObject*) const override { return false; }
-    bool hasSameStyle(RenderObject*) const override { return false; }
-    bool isStaticText() const override { return false; }
-    bool hasUnderline() const override { return false; }
-    bool hasHighlighting() const override { return false; }
-
-    bool supportsDatetimeAttribute() const override { return false; }
-    const AtomString& datetimeAttributeValue() const override { return nullAtom(); }
-
-    bool canSetFocusAttribute() const override { return false; }
-    bool canSetTextRangeAttributes() const override { return false; }
-    bool canSetValueAttribute() const override { return false; }
-    bool canSetNumericValue() const override { return false; }
-    bool canSetSelectedAttribute() const override { return false; }
-    bool canSetSelectedChildrenAttribute() const override { return false; }
-    bool canSetExpandedAttribute() const override { return false; }
-
-    Element* element() const override { return nullptr; }
-    Node* node() const override { return nullptr; }
-    RenderObject* renderer() const override { return nullptr; }
-
-    bool accessibilityIsIgnored() const override { return boolAttributeValue(AXPropertyName::IsAccessibilityIgnored); }
-    AccessibilityObjectInclusion defaultObjectInclusion() const override { return AccessibilityObjectInclusion::DefaultBehavior; }
-    bool accessibilityIsIgnoredByDefault() const override { return false; }
-
-    bool isShowingValidationMessage() const override { return false; }
-    String validationMessage() const override { return String(); }
-
-    unsigned blockquoteLevel() const override { return 0; }
-    int headingLevel() const override { return 0; }
-    int tableLevel() const override { return 0; }
-    AccessibilityButtonState checkboxOrRadioValue() const override { return AccessibilityButtonState::Off; }
-    String valueDescription() const override { return String(); }
-    float valueForRange() const override { return 0; }
-    float maxValueForRange() const override { return 0; }
-    float minValueForRange() const override { return 0; }
-    float stepValueForRange() const override { return 0; }
-    AXCoreObject* selectedRadioButton() override { return nullptr; }
-    AXCoreObject* selectedTabItem() override { return nullptr; }
-    AXCoreObject* selectedListItem() override { return nullptr; }
-    int layoutCount() const override { return 0; }
-    double estimatedLoadingProgress() const override { return 0; }
-
-    bool supportsARIAOwns() const override { return false; }
-    bool isActiveDescendantOfFocusedContainer() const override { return false; }
-    void ariaActiveDescendantReferencingElements(AccessibilityChildrenVector&) const override { }
-    void ariaControlsElements(AccessibilityChildrenVector&) const override { }
-    void ariaControlsReferencingElements(AccessibilityChildrenVector&) const override { }
-    void ariaDescribedByElements(AccessibilityChildrenVector&) const override { }
-    void ariaDescribedByReferencingElements(AccessibilityChildrenVector&) const override { }
-    void ariaDetailsElements(AccessibilityChildrenVector&) const override { }
-    void ariaDetailsReferencingElements(AccessibilityChildrenVector&) const override { }
-    void ariaErrorMessageElements(AccessibilityChildrenVector&) const override { }
-    void ariaErrorMessageReferencingElements(AccessibilityChildrenVector&) const override { }
-    void ariaFlowToElements(AccessibilityChildrenVector&) const override { }
-    void ariaFlowToReferencingElements(AccessibilityChildrenVector&) const override { }
-    void ariaLabelledByElements(AccessibilityChildrenVector&) const override { }
-    void ariaLabelledByReferencingElements(AccessibilityChildrenVector&) const override { }
-    void ariaOwnsElements(AccessibilityChildrenVector&) const override { }
-    void ariaOwnsReferencingElements(AccessibilityChildrenVector&) const override { }
-
-    bool hasPopup() const override { return false; }
-    String popupValue() const override { return String(); }
-    bool hasDatalist() const override { return false; }
-    bool supportsHasPopup() const override { return false; }
-    bool pressedIsPresent() const override { return false; }
-    bool ariaIsMultiline() const override { return false; }
-    String invalidStatus() const override { return String(); }
-    bool supportsPressed() const override { return false; }
-    bool supportsExpanded() const override { return false; }
-    bool supportsChecked() const override { return false; }
-    AccessibilitySortDirection sortDirection() const override { return AccessibilitySortDirection::None; }
-    bool canvasHasFallbackContent() const override { return false; }
-    bool supportsRangeValue() const override { return false; }
-    const AtomString& identifierAttribute() const override { return nullAtom(); }
-    const AtomString& linkRelValue() const override { return nullAtom(); }
-    void classList(Vector<String>&) const override { }
-    AccessibilityCurrentState currentState() const override { return AccessibilityCurrentState::False; }
-    String currentValue() const override { return String(); }
-    bool supportsCurrent() const override { return false; }
-    const String keyShortcutsValue() const override { return String(); }
-
-    // This function checks if the object should be ignored when there's a modal dialog displayed.
-    bool ignoredFromModalPresence() const override { return false; }
-    bool isModalDescendant(Node*) const override { return false; }
-    bool isModalNode() const override { return false; }
-
-    bool supportsSetSize() const override { return false; }
-    bool supportsPosInSet() const override { return false; }
-    int setSize() const override { return 0; }
-    int posInSet() const override { return 0; }
-
-    bool supportsARIADropping() const override { return false; }
-    bool supportsARIADragging() const override { return false; }
-    bool isARIAGrabbed() override { return false; }
-    void setARIAGrabbed(bool) override { }
-    Vector<String> determineARIADropEffects() override { return Vector<String>(); }
-
-    AXCoreObject* accessibilityHitTest(const IntPoint&) const override;
-    AXCoreObject* elementAccessibilityHitTest(const IntPoint&) const override { return nullptr; }
-
-    AXCoreObject* focusedUIElement() const override;
-
-    AXCoreObject* firstChild() const override { return nullptr; }
-    AXCoreObject* lastChild() const override { return nullptr; }
-    AXCoreObject* previousSibling() const override { return nullptr; }
-    AXCoreObject* nextSibling() const override { return nullptr; }
-    AXCoreObject* nextSiblingUnignored(int) const override { return nullptr; }
-    AXCoreObject* previousSiblingUnignored(int) const override { return nullptr; }
-    AXCoreObject* parentObject() const override { return nullptr; }
-    AXCoreObject* parentObjectUnignored() const override;
-    AXCoreObject* parentObjectIfExists() const override { return nullptr; }
-    void findMatchingObjects(AccessibilitySearchCriteria*, AccessibilityChildrenVector&) override { }
-    bool isDescendantOfBarrenParent() const override { return false; }
-    bool isDescendantOfRole(AccessibilityRole) const override { return false; }
-
-    Vector<RefPtr<Range>> findTextRanges(AccessibilitySearchTextCriteria const&) const override { return Vector<RefPtr<Range>>(); }
-    Vector<String> performTextOperation(AccessibilityTextOperation const&) override { return Vector<String>(); }
-
-    AXCoreObject* observableObject() const override { return nullptr; }
-    void linkedUIElements(AccessibilityChildrenVector&) const override { }
-    AXCoreObject* titleUIElement() const override { return nullptr; }
-    bool exposesTitleUIElement() const override { return false; }
-    AXCoreObject* correspondingLabelForControlElement() const override { return nullptr; }
-    AXCoreObject* correspondingControlForLabelElement() const override { return nullptr; }
-    AXCoreObject* scrollBar(AccessibilityOrientation) override { return nullptr; }
-
-    AccessibilityRole ariaRoleAttribute() const override { return AccessibilityRole::Unknown; }
-    bool isPresentationalChildOfAriaRole() const override { return false; }
-    bool ariaRoleHasPresentationalChildren() const override { return false; }
-    bool inheritsPresentationalRole() const override { return false; }
-
-    void accessibilityText(Vector<AccessibilityText>&) const override { }
-    String computedLabel() override { return String(); }
-
-    void setAccessibleName(const AtomString&) override { }
-    bool hasAttributesRequiredForInclusion() const override { return false; }
-
-    String accessibilityDescription() const override { return String(); }
-    String title() const override { return String(); }
-    String helpText() const override { return String(); }
-
-    bool isARIAStaticText() const override { return false; }
-    String stringValue() const override { return String(); }
-    String textUnderElement(AccessibilityTextUnderElementMode = AccessibilityTextUnderElementMode()) const override { return String(); }
-    String text() const override { return String(); }
-    int textLength() const override { return 0; }
-    String ariaLabeledByAttribute() const override { return String(); }
-    String ariaDescribedByAttribute() const override { return String(); }
-    const String placeholderValue() const override { return String(); }
-    bool accessibleNameDerivesFromContent() const override { return false; }
-
-    String expandedTextValue() const override { return String(); }
-    bool supportsExpandedTextValue() const override { return false; }
-
-    void elementsFromAttribute(Vector<Element*>&, const QualifiedName&) const override { }
-
-    void colorValue(int&, int&, int&) const override { }
-
-    AccessibilityRole roleValue() const override { return static_cast<AccessibilityRole>(intAttributeValue(AXPropertyName::RoleValue)); }
-    String rolePlatformString() const override { return stringAttributeValue(AXPropertyName::RolePlatformString); }
-    String roleDescription() const override { return stringAttributeValue(AXPropertyName::RoleDescription); }
-    String ariaLandmarkRoleDescription() const override { return stringAttributeValue(AXPropertyName::ARIALandmarkRoleDescription); }
-
-    AXObjectCache* axObjectCache() const override { return nullptr; }
-
-    Element* anchorElement() const override { return nullptr; }
-    bool supportsPressAction() const override { return false; }
-    Element* actionElement() const override { return nullptr; }
-    LayoutRect boundingBoxRect() const override { return rectAttributeValue<LayoutRect>(AXPropertyName::BoundingBoxRect); }
-    LayoutRect elementRect() const override { return rectAttributeValue<LayoutRect>(AXPropertyName::ElementRect); }
-    IntPoint clickPoint() override { return IntPoint(); }
-    Path elementPath() const override { return Path(); }
-    bool supportsPath() const override { return false; }
-
-    TextIteratorBehavior textIteratorBehaviorForTextRange() const override { return TextIteratorDefaultBehavior; }
-    PlainTextRange selectedTextRange() const override { return PlainTextRange(); }
-    unsigned selectionStart() const override { return 0; }
-    unsigned selectionEnd() const override { return 0; }
-
-    URL url() const override { return URL(); }
-    VisibleSelection selection() const override { return VisibleSelection(); }
-    String selectedText() const override { return String(); }
-    const AtomString& accessKey() const override { return nullAtom(); }
-    const String& actionVerb() const override { return nullAtom(); }
-    Widget* widget() const override { return nullptr; }
-    Widget* widgetForAttachmentView() const override { return nullptr; }
-    Page* page() const override { return nullptr; }
-    Document* document() const override { return nullptr; }
-    FrameView* documentFrameView() const override { return nullptr; }
-    Frame* frame() const override { return nullptr; }
-    Frame* mainFrame() const override { return nullptr; }
-    Document* topDocument() const override { return nullptr; }
-    ScrollView* scrollViewAncestor() const override { return nullptr; }
-    String language() const override { return String(); }
-    unsigned hierarchicalLevel() const override { return 0; }
-
-    void setFocused(bool) override { }
-    void setSelectedText(const String&) override { }
-    void setSelectedTextRange(const PlainTextRange&) override { }
-    void setValue(const String&) override { }
-    bool replaceTextInRange(const String&, const PlainTextRange&) override { return false; }
-    bool insertText(const String&) override { return false; }
-
-    void setValue(float) override { }
-    void setSelected(bool) override { }
-    void setSelectedRows(AccessibilityChildrenVector&) override { }
-
-    void makeRangeVisible(const PlainTextRange&) override { }
-    bool press() override { return false; }
-    bool performDefaultAction() override { return false; }
-
-    AccessibilityOrientation orientation() const override { return AccessibilityOrientation::Undefined; }
-    void increment() override { }
-    void decrement() override { }
-
-    void childrenChanged() override { }
-    void textChanged() override { }
-    void updateAccessibilityRole() override { }
-    const AccessibilityChildrenVector& children(bool updateChildrenIfNeeded = true) override;
-    void addChildren() override { }
-    void addChild(AXCoreObject*) override { }
-    void insertChild(AXCoreObject*, unsigned) override { }
-
-    bool shouldIgnoreAttributeRole() const override { return false; }
-
-    bool canHaveChildren() const override { return false; }
-    bool hasChildren() const override { return false; }
-    void updateChildrenIfNecessary() override { }
-    void setNeedsToUpdateChildren() override { }
-    void setNeedsToUpdateSubtree() override { };
-    void clearChildren() override { }
-    bool needsToUpdateChildren() const override { return false; }
-    void detachFromParent() override { }
-    bool isDetachedFromParent() override { return false; }
-
-    bool canHaveSelectedChildren() const override { return false; }
-    void selectedChildren(AccessibilityChildrenVector&) override { }
-    void visibleChildren(AccessibilityChildrenVector&) override { }
-    void tabChildren(AccessibilityChildrenVector&) override { }
-    bool shouldFocusActiveDescendant() const override { return false; }
-    AXCoreObject* activeDescendant() const override { return nullptr; }
-    void handleActiveDescendantChanged() override { }
-    void handleAriaExpandedChanged() override { }
-    bool isDescendantOfObject(const AXCoreObject*) const override { return false; }
-    bool isAncestorOfObject(const AXCoreObject*) const override { return false; }
-    AXCoreObject* firstAnonymousBlockChild() const override { return nullptr; }
-
-    bool hasAttribute(const QualifiedName&) const override { return false; }
-    const AtomString& getAttribute(const QualifiedName&) const override { return nullAtom(); }
-    bool hasTagName(const QualifiedName&) const override { return false; }
-
-    VisiblePositionRange visiblePositionRange() const override { return VisiblePositionRange(); }
-    VisiblePositionRange visiblePositionRangeForLine(unsigned) const override { return VisiblePositionRange(); }
-    RefPtr<Range> elementRange() const override { return nullptr; }
-    VisiblePositionRange visiblePositionRangeForUnorderedPositions(const VisiblePosition&, const VisiblePosition&) const override { return VisiblePositionRange(); }
-    VisiblePositionRange positionOfLeftWord(const VisiblePosition&) const override { return VisiblePositionRange(); }
-    VisiblePositionRange positionOfRightWord(const VisiblePosition&) const override { return VisiblePositionRange(); }
-    VisiblePositionRange leftLineVisiblePositionRange(const VisiblePosition&) const override { return VisiblePositionRange(); }
-    VisiblePositionRange rightLineVisiblePositionRange(const VisiblePosition&) const override { return VisiblePositionRange(); }
-    VisiblePositionRange sentenceForPosition(const VisiblePosition&) const override { return VisiblePositionRange(); }
-    VisiblePositionRange paragraphForPosition(const VisiblePosition&) const override { return VisiblePositionRange(); }
-    VisiblePositionRange styleRangeForPosition(const VisiblePosition&) const override { return VisiblePositionRange(); }
-    VisiblePositionRange visiblePositionRangeForRange(const PlainTextRange&) const override { return VisiblePositionRange(); }
-    VisiblePositionRange lineRangeForPosition(const VisiblePosition&) const override { return VisiblePositionRange(); }
-
-    RefPtr<Range> rangeForPlainTextRange(const PlainTextRange&) const override { return nullptr; }
-
-    String stringForRange(RefPtr<Range>) const override { return String(); }
-    IntRect boundsForVisiblePositionRange(const VisiblePositionRange&) const override { return IntRect(); }
-    IntRect boundsForRange(const RefPtr<Range>) const override { return IntRect(); }
-    int lengthForVisiblePositionRange(const VisiblePositionRange&) const override { return 0; }
-    void setSelectedVisiblePositionRange(const VisiblePositionRange&) const override { }
-
-    VisiblePosition visiblePositionForBounds(const IntRect&, AccessibilityVisiblePositionForBounds) const override { return VisiblePosition(); }
-    VisiblePosition visiblePositionForPoint(const IntPoint&) const override { return VisiblePosition(); }
-    VisiblePosition nextVisiblePosition(const VisiblePosition&) const override { return VisiblePosition(); }
-    VisiblePosition previousVisiblePosition(const VisiblePosition&) const override { return VisiblePosition(); }
-    VisiblePosition nextWordEnd(const VisiblePosition&) const override { return VisiblePosition(); }
-    VisiblePosition previousWordStart(const VisiblePosition&) const override { return VisiblePosition(); }
-    VisiblePosition nextLineEndPosition(const VisiblePosition&) const override { return VisiblePosition(); }
-    VisiblePosition previousLineStartPosition(const VisiblePosition&) const override { return VisiblePosition(); }
-    VisiblePosition nextSentenceEndPosition(const VisiblePosition&) const override { return VisiblePosition(); }
-    VisiblePosition previousSentenceStartPosition(const VisiblePosition&) const override { return VisiblePosition(); }
-    VisiblePosition nextParagraphEndPosition(const VisiblePosition&) const override { return VisiblePosition(); }
-    VisiblePosition previousParagraphStartPosition(const VisiblePosition&) const override { return VisiblePosition(); }
-    VisiblePosition visiblePositionForIndex(unsigned, bool /*lastIndexOK */) const override { return VisiblePosition(); }
-
-    VisiblePosition visiblePositionForIndex(int) const override { return VisiblePosition(); }
-    int indexForVisiblePosition(const VisiblePosition&) const override { return 0; }
-
-    AXCoreObject* accessibilityObjectForPosition(const VisiblePosition&) const override { return nullptr; }
-    int lineForPosition(const VisiblePosition&) const override { return 0; }
-    PlainTextRange plainTextRangeForVisiblePositionRange(const VisiblePositionRange&) const override { return PlainTextRange(); }
-    int index(const VisiblePosition&) const override { return 0; }
-
-    void lineBreaks(Vector<int>&) const override { }
-    PlainTextRange doAXRangeForLine(unsigned) const override { return PlainTextRange(); }
-    PlainTextRange doAXRangeForPosition(const IntPoint&) const override { return PlainTextRange(); }
-    PlainTextRange doAXRangeForIndex(unsigned) const override { return PlainTextRange(); }
-    PlainTextRange doAXStyleRangeForIndex(unsigned) const override { return PlainTextRange(); }
-
-    String doAXStringForRange(const PlainTextRange&) const override { return String(); }
-    IntRect doAXBoundsForRange(const PlainTextRange&) const override { return IntRect(); }
-    IntRect doAXBoundsForRangeUsingCharacterOffset(const PlainTextRange&) const override { return IntRect(); }
-
-    unsigned doAXLineForIndex(unsigned) override { return 0; }
-
-    String computedRoleString() const override { return String(); }
-
-    // MSAA
-    String stringValueForMSAA() const override { return String(); }
-    String stringRoleForMSAA() const override { return String(); }
-    String nameForMSAA() const override { return String(); }
-    String descriptionForMSAA() const override { return String(); }
-    AccessibilityRole roleValueForMSAA() const override { return AccessibilityRole::Unknown; }
-
-    String passwordFieldValue() const override { return String(); }
-    bool isValueAutofilled() const override { return false; }
-    bool isValueAutofillAvailable() const override { return false; }
-    AutoFillButtonType valueAutofillButtonType() const override { return AutoFillButtonType::None; }
-
-    void ariaTreeRows(AccessibilityChildrenVector&) override { }
-    void ariaTreeItemDisclosedRows(AccessibilityChildrenVector&) override { }
-    void ariaTreeItemContent(AccessibilityChildrenVector&) override { }
-
-    bool supportsLiveRegion(bool = true) const override { return false; }
-    bool isInsideLiveRegion(bool = true) const override { return false; }
-    AXCoreObject* liveRegionAncestor(bool = true) const override { return nullptr; }
-    const String liveRegionStatus() const override { return String(); }
-    const String liveRegionRelevant() const override { return String(); }
-    bool liveRegionAtomic() const override { return false; }
-    bool isBusy() const override { return false; }
-
-    bool hasContentEditableAttributeSet() const override { return false; }
-
-    bool supportsReadOnly() const override { return false; }
-    String readOnlyValue() const override { return String(); }
-
-    bool supportsAutoComplete() const override { return false; }
-    String autoCompleteValue() const override { return String(); }
-
-    bool supportsARIAAttributes() const override { return false; }
-
-    OptionSet<SpeakAs> speakAsProperty() const override { return OptionSet<SpeakAs>(); }
-
-    void scrollToMakeVisible() const override { }
-    void scrollToMakeVisibleWithSubFocus(const IntRect&) const override { }
-    void scrollToGlobalPoint(const IntPoint&) const override { }
-
-    bool scrollByPage(ScrollByPageDirection) const override { return false; }
-    IntPoint scrollPosition() const override { return IntPoint(); }
-    IntSize scrollContentsSize() const override { return IntSize(); }
-    IntRect scrollVisibleContentRect() const override { return IntRect(); }
-    void scrollToMakeVisible(const ScrollRectToVisibleOptions&) const override { }
-
-    bool lastKnownIsIgnoredValue() override { return false; }
-    void setLastKnownIsIgnoredValue(bool) override { }
-
-    void notifyIfIgnoredValueChanged() override { }
-
-    bool isMathElement() const override { return boolAttributeValue(AXPropertyName::IsMathElement); }
-    bool isMathFraction() const override { return boolAttributeValue(AXPropertyName::IsMathFraction); }
-    bool isMathFenced() const override { return boolAttributeValue(AXPropertyName::IsMathFenced); }
-    bool isMathSubscriptSuperscript() const override { return boolAttributeValue(AXPropertyName::IsMathSubscriptSuperscript); }
-    bool isMathRow() const override { return boolAttributeValue(AXPropertyName::IsMathRow); }
-    bool isMathUnderOver() const override { return boolAttributeValue(AXPropertyName::IsMathUnderOver); }
-    bool isMathRoot() const override { return boolAttributeValue(AXPropertyName::IsMathRoot); }
-    bool isMathSquareRoot() const override { return boolAttributeValue(AXPropertyName::IsMathSquareRoot); }
-    bool isMathText() const override { return boolAttributeValue(AXPropertyName::IsMathText); }
-    bool isMathNumber() const override { return boolAttributeValue(AXPropertyName::IsMathNumber); }
-    bool isMathOperator() const override { return boolAttributeValue(AXPropertyName::IsMathOperator); }
-    bool isMathFenceOperator() const override { return boolAttributeValue(AXPropertyName::IsMathFenceOperator); }
-    bool isMathSeparatorOperator() const override { return boolAttributeValue(AXPropertyName::IsMathSeparatorOperator); }
-    bool isMathIdentifier() const override { return boolAttributeValue(AXPropertyName::IsMathIdentifier); }
-    bool isMathTable() const override { return boolAttributeValue(AXPropertyName::IsMathTable); }
-    bool isMathTableRow() const override { return boolAttributeValue(AXPropertyName::IsMathTableRow); }
-    bool isMathTableCell() const override { return boolAttributeValue(AXPropertyName::IsMathTableCell); }
-    bool isMathMultiscript() const override { return boolAttributeValue(AXPropertyName::IsMathMultiscript); }
-    bool isMathToken() const override { return boolAttributeValue(AXPropertyName::IsMathToken); }
-    bool isMathScriptObject(AccessibilityMathScriptObjectType) const override { return false; }
-    bool isMathMultiscriptObject(AccessibilityMathMultiscriptObjectType) const override { return false; }
-
-    AXCoreObject* mathRadicandObject() override { return objectAttributeValue(AXPropertyName::MathRadicandObject); }
-    AXCoreObject* mathRootIndexObject() override { return objectAttributeValue(AXPropertyName::MathRootIndexObject); }
-
-    AXCoreObject* mathUnderObject() override { return objectAttributeValue(AXPropertyName::MathUnderObject); }
-    AXCoreObject* mathOverObject() override { return objectAttributeValue(AXPropertyName::MathOverObject); }
-
-    AXCoreObject* mathNumeratorObject() override { return objectAttributeValue(AXPropertyName::MathNumeratorObject); }
-    AXCoreObject* mathDenominatorObject() override { return objectAttributeValue(AXPropertyName::MathDenominatorObject); }
-
-    AXCoreObject* mathBaseObject() override { return objectAttributeValue(AXPropertyName::MathBaseObject); }
-    AXCoreObject* mathSubscriptObject() override { return objectAttributeValue(AXPropertyName::MathSubscriptObject); }
-    AXCoreObject* mathSuperscriptObject() override { return objectAttributeValue(AXPropertyName::MathSuperscriptObject); }
-
-    String mathFencedOpenString() const override { return stringAttributeValue(AXPropertyName::MathFencedOpenString); }
-    String mathFencedCloseString() const override { return stringAttributeValue(AXPropertyName::MathFencedCloseString); }
-    int mathLineThickness() const override { return intAttributeValue(AXPropertyName::MathLineThickness); }
-    bool isAnonymousMathOperator() const override { return boolAttributeValue(AXPropertyName::IsAnonymousMathOperator); }
-
-    void mathPrescripts(AccessibilityMathMultiscriptPairs&) override { }
-    void mathPostscripts(AccessibilityMathMultiscriptPairs&) override { }
-
-    bool isAXHidden() const override { return false; }
-    bool isDOMHidden() const override { return false; }
-    bool isHidden() const override { return false; }
-
-    void setWrapper(AccessibilityObjectWrapper* wrapper) override { m_wrapper = wrapper; }
-
-    void overrideAttachmentParent(AXCoreObject*) override { }
-
-    bool accessibilityIgnoreAttachment() const override { return false; }
-    AccessibilityObjectInclusion accessibilityPlatformIncludesObject() const override { return AccessibilityObjectInclusion::DefaultBehavior; }
-
-#if PLATFORM(IOS_FAMILY)
-    int accessibilityPasswordFieldLength() override { return 0; }
-    bool hasTouchEventListener() const override { return false; }
-    bool isInputTypePopupButton() const override { return false; }
-#endif
-
-    void updateBackingStore() override;
-
-#if PLATFORM(COCOA)
-    bool preventKeyboardDOMEventDispatch() const override { return false; }
-    void setPreventKeyboardDOMEventDispatch(bool) override { }
-    bool fileUploadButtonReturnsValueInTitle() const override { return false; }
-    String speechHintAttributeValue() const override { return stringAttributeValue(AXPropertyName::SpeechHint); }
-    String descriptionAttributeValue() const override { return stringAttributeValue(AXPropertyName::Description); }
-    String helpTextAttributeValue() const override { return stringAttributeValue(AXPropertyName::HelpText); }
-    String titleAttributeValue() const override { return stringAttributeValue(AXPropertyName::Title); }
-#endif
-
-#if PLATFORM(COCOA) && !PLATFORM(IOS_FAMILY)
-    bool caretBrowsingEnabled() const override { return false; }
-    void setCaretBrowsingEnabled(bool) override { }
-#endif
-
-    AXCoreObject* focusableAncestor() override { return nullptr; }
-    AXCoreObject* editableAncestor() override { return nullptr; }
-    AXCoreObject* highestEditableAncestor() override { return nullptr; }
-
-    const AccessibilityScrollView* ancestorAccessibilityScrollView(bool) const override { return nullptr; }
-
-    void setIsIgnoredFromParentData(AccessibilityIsIgnoredFromParentData&) override { };
-    void clearIsIgnoredFromParentData() override { }
-    void setIsIgnoredFromParentDataForChild(AXCoreObject*) override { }
 
+    AXID parent() const { return m_parent; }
+    
+    AXIsolatedTreeID treeIdentifier() const { return m_treeIdentifier; }
+    AXIsolatedTree* tree() const;
+    
+    AXIsolatedObject() = default;
+    AXIsolatedObject(AXCoreObject&, bool isRoot);
+    void initializeAttributeData(AXCoreObject&, bool isRoot);
+    
     enum class AXPropertyName : uint8_t {
         None = 0,
+        AccessKey,
+        ActionVerb,
+        AccessibilityButtonState,
+        AccessibilityText,
+        AutoCompleteValue,
+        ARIAControlsElements,
+        ARIADetailsElements,
+        ARIADropEffects,
+        ARIAErrorMessageElements,
+        ARIAIsMultiline,
+        ARIAFlowToElements,
+        ARIALandmarkRoleDescription,
+        ARIATreeItemContent,
+        ARIATreeItemDisclosedRows,
+        ARIATreeRows,
+        ARIARoleAttribute,
+        ARIAOwnsElements,
+        BlockquoteLevel,
         BoundingBoxRect,
+        CanHaveSelectedChildren,
+        CanSetExpandedAttribute,
+        CanSetFocusAttribute,
+        CanSetNumericValue,
+        CanSetSelectedAttribute,
+        CanSetSelectedChildrenAttribute,
+        CanSetTextRangeAttributes,
+        CanSetValueAttribute,
+        CanvasHasFallbackContent,
+        CaretBrowsingEnabled,
+        ClassList,
+        ClickPoint,
+        ColorValue,
+        ComputedLabel,
+        ComputedRoleString,
+        CurrentState,
+        CurrentValue,
+        DatetimeAttributeValue,
         Description,
+        DocumentEncoding,
+        DocumentURI,
+        EditableAncestor,
         ElementRect,
+        EstimatedLoadingProgress,
+        ExpandedTextValue,
+        ExposesTitleUIElement,
+        FileUploadButtonReturnsValueInTitle,
+        FocusableAncestor,
+        HasARIAValueNow,
+        HasPopup,
+        HeadingLevel,
         HelpText,
+        HierarchicalLevel,
+        HighestEditableAncestor,
+        HorizontalScrollBar,
+        IdentifierAttribute,
+        InvalidStatus,
         IsAccessibilityIgnored,
+        IsActiveDescendantOfFocusedContainer,
         IsAnonymousMathOperator,
+        IsARIAGrabbed,
+        IsARIATreeGridRow,
         IsAttachment,
+        IsButton,
+        IsBusy,
         IsChecked,
         IsCollapsed,
+        IsControl,
         IsEnabled,
         IsExpanded,
+        IsFieldset,
         IsFileUploadButton,
         IsFocused,
+        IsGroup,
         IsImage,
         IsImageMapLink,
         IsIndeterminate,
+        IsInlineText,
+        IsInputImage,
+        IsInsideLiveRegion,
         IsLink,
         IsLinked,
+        IsList,
+        IsListBox,
         IsLoaded,
+        IsHeading,
         IsHovered,
         IsMathElement,
         IsMathFraction,
@@ -677,23 +181,57 @@ private:
         IsMathMultiscript,
         IsMathToken,
         IsMathScriptObject,
-        IsMediaControlLabel,
+        IsMediaTimeline,
+        IsMenu,
+        IsMenuBar,
+        IsMenuButton,
+        IsMenuItem,
+        IsMenuList,
+        IsMenuListOption,
+        IsMenuListPopup,
+        IsMenuRelated,
+        IsMeter,
         IsMultiSelectable,
         IsOffScreen,
         IsOnScreen,
+        IsOutput,
+        IsPasswordField,
         IsPressed,
+        IsProgressIndicator,
+        IsRangeControl,
         IsRequired,
         IsScrollbar,
+        IsSearchField,
         IsSelected,
         IsSelectedOptionActive,
+        IsShowingValidationMessage,
+        IsSlider,
+        IsStyleFormatGroup,
+        IsTable,
+        IsTableCell,
+        IsTableColumn,
+        IsTableRow,
+        IsTextControl,
         IsTree,
         IsTreeItem,
         IsUnvisited,
+        IsValueAutofilled,
+        IsValueAutofillAvailable,
         IsVisible,
         IsVisited,
+        KeyShortcutsValue,
+        Language,
+        LayoutCount,
+        LinkRelValue,
+        LinkedUIElements,
+        LiveRegionAtomic,
+        LiveRegionRelevant,
+        LiveRegionStatus,
         MathFencedOpenString,
         MathFencedCloseString,
         MathLineThickness,
+        MathPrescripts,
+        MathPostscripts,
         MathRadicandObject,
         MathRootIndexObject,
         MathUnderObject,
@@ -703,37 +241,557 @@ private:
         MathBaseObject,
         MathSubscriptObject,
         MathSuperscriptObject,
+        MaxValueForRange,
+        MinValueForRange,
+        Orientation,
+        PlaceholderValue,
+        PressedIsPresent,
+        PopupValue,
+        PosInSet,
+        PreventKeyboardDOMEventDispatch,
+        ReadOnlyValue,
         RelativeFrame,
         RoleValue,
         RolePlatformString,
         RoleDescription,
-        ARIALandmarkRoleDescription,
+        SelectedChildren,
+        SelectedRadioButton,
+        SelectedTabItem,
+        SessionID,
+        SetSize,
+        SortDirection,
+        SpeakAs,
         SpeechHint,
+        SupportsARIADragging,
+        SupportsARIADropping,
+        SupportsARIAOwns,
+        SupportsCurrent,
+        SupportsDatetimeAttribute,
+        SupportsExpanded,
+        SupportsExpandedTextValue,
+        SupportsLiveRegion,
+        SupportsRangeValue,
+        SupportsPosInSet,
+        SupportsPressAction,
         SupportsRequiredAttribute,
+        SupportsSetSize,
+        TabChildren,
+        TableLevel,
+        TagName,
+        TextLength,
         Title,
+        TitleUIElement,
+        URL,
+        ValueAutofillButtonType,
+        ValueDescription,
+        ValueForRange,
+        ValidationMessage,
+        VerticalScrollBar,
+        VisibleChildren,
     };
-
-    AXID parent() const { return m_parent; }
-
-    AXIsolatedTreeID treeIdentifier() const { return m_treeIdentifier; }
-    AXIsolatedTree* tree() const;
-
-    AXIsolatedObject() = default;
-    AXIsolatedObject(AXCoreObject&);
-    void initializeAttributeData(AXCoreObject&);
-
-    using AttributeValueVariant = Variant<std::nullptr_t, String, bool, int, unsigned, double, LayoutRect, AXID>;
+    
+    typedef std::pair<AXID, AXID> AccessibilityIsolatedTreeMathMultiscriptPair;
+    struct AccessibilityIsolatedTreeText {
+        String text;
+        AccessibilityTextSource textSource;
+        Vector<AXID> textElements;
+    };
+    
+    using AttributeValueVariant = Variant<std::nullptr_t, String, bool, int, unsigned, double, float, uint64_t, Color, URL, LayoutRect, AXID, IntPoint, OptionSet<SpeakAs>, Vector<AccessibilityIsolatedTreeText>, Vector<AXID>, Vector<AccessibilityIsolatedTreeMathMultiscriptPair>, Vector<String>>;
     void setProperty(AXPropertyName, AttributeValueVariant&&, bool shouldRemove = false);
     void setObjectProperty(AXPropertyName, AXCoreObject*);
-    
+    void setObjectVectorProperty(AXPropertyName, AccessibilityChildrenVector&);
+
     bool boolAttributeValue(AXPropertyName) const;
     const String stringAttributeValue(AXPropertyName) const;
     int intAttributeValue(AXPropertyName) const;
     unsigned unsignedAttributeValue(AXPropertyName) const;
     double doubleAttributeValue(AXPropertyName) const;
-    template<typename T> T rectAttributeValue(AXPropertyName) const;
+    float floatAttributeValue(AXPropertyName) const;
     AXCoreObject* objectAttributeValue(AXPropertyName) const;
+    IntPoint intPointAttributeValue(AXPropertyName) const;
+    Color colorAttributeValue(AXPropertyName) const;
+    URL urlAttributeValue(AXPropertyName) const;
+    uint64_t uint64AttributeValue(AXPropertyName) const;
+    template<typename T> T rectAttributeValue(AXPropertyName) const;
+    template<typename T> Vector<T> vectorAttributeValue(AXPropertyName) const;
+    template<typename T> OptionSet<T> optionSetAttributeValue(AXPropertyName) const;
 
+    void fillChildrenVectorForProperty(AXPropertyName, AccessibilityChildrenVector&) const;
+    void setMathscripts(AXPropertyName, AXCoreObject&);
+    void insertMathPairs(Vector<AccessibilityIsolatedTreeMathMultiscriptPair>&, AccessibilityMathMultiscriptPairs&);
+    
+    // Attribute retrieval overrides.
+    bool isHeading() const override { return boolAttributeValue(AXPropertyName::IsHeading); }
+    bool isLink() const override { return boolAttributeValue(AXPropertyName::IsLink); }
+    bool isImage() const override { return boolAttributeValue(AXPropertyName::IsImage); }
+    bool isPasswordField() const override { return boolAttributeValue(AXPropertyName::IsPasswordField); }
+    bool isSearchField() const override { return boolAttributeValue(AXPropertyName::IsSearchField); }
+    bool isAttachment() const override { return boolAttributeValue(AXPropertyName::IsAttachment); }
+    bool isMediaTimeline() const override { return boolAttributeValue(AXPropertyName::IsMediaTimeline); }
+    bool isMenuRelated() const override { return boolAttributeValue(AXPropertyName::IsMenuRelated); }
+    bool isMenu() const override { return boolAttributeValue(AXPropertyName::IsMenu); }
+    bool isMenuBar() const override { return boolAttributeValue(AXPropertyName::IsMenuBar); }
+    bool isMenuButton() const override { return boolAttributeValue(AXPropertyName::IsMenuButton); }
+    bool isMenuItem() const override { return boolAttributeValue(AXPropertyName::IsMenuItem); }
+    bool isFileUploadButton() const override { return boolAttributeValue(AXPropertyName::IsFileUploadButton); }
+    bool isInputImage() const override { return boolAttributeValue(AXPropertyName::IsInputImage); }
+    bool isProgressIndicator() const override { return boolAttributeValue(AXPropertyName::IsProgressIndicator); }
+    bool isSlider() const override { return boolAttributeValue(AXPropertyName::IsSlider); }
+    bool isControl() const override { return boolAttributeValue(AXPropertyName::IsControl); }
+    bool isList() const override { return boolAttributeValue(AXPropertyName::IsList); }
+    bool isTable() const override { return boolAttributeValue(AXPropertyName::IsTable); }
+    bool isTableRow() const override { return boolAttributeValue(AXPropertyName::IsTableRow); }
+    bool isTableColumn() const override { return boolAttributeValue(AXPropertyName::IsTableColumn); }
+    bool isTableCell() const override { return boolAttributeValue(AXPropertyName::IsTableCell); }
+    bool isFieldset() const override { return boolAttributeValue(AXPropertyName::IsFieldset); }
+    bool isGroup() const override { return boolAttributeValue(AXPropertyName::IsGroup); }
+    bool isARIATreeGridRow() const override { return boolAttributeValue(AXPropertyName::IsARIATreeGridRow); }
+    bool isMenuList() const override { return boolAttributeValue(AXPropertyName::IsMenuList); }
+    bool isMenuListPopup() const override { return boolAttributeValue(AXPropertyName::IsMenuListPopup); }
+    bool isMenuListOption() const override { return boolAttributeValue(AXPropertyName::IsMenuListOption); }
+    bool isTextControl() const override { return boolAttributeValue(AXPropertyName::IsTextControl); }
+    bool isButton() const override { return boolAttributeValue(AXPropertyName::IsButton); }
+    bool isRangeControl() const override { return boolAttributeValue(AXPropertyName::IsRangeControl); }
+    bool isMeter() const override { return boolAttributeValue(AXPropertyName::IsMeter); }
+    bool isStyleFormatGroup() const override { return boolAttributeValue(AXPropertyName::IsStyleFormatGroup); }
+    bool isOutput() const override { return boolAttributeValue(AXPropertyName::IsOutput); }
+    bool isChecked() const override { return boolAttributeValue(AXPropertyName::IsChecked); }
+    bool isEnabled() const override { return boolAttributeValue(AXPropertyName::IsEnabled); }
+    bool isSelected() const override { return boolAttributeValue(AXPropertyName::IsSelected); }
+    bool isFocused() const override { return boolAttributeValue(AXPropertyName::IsFocused); }
+    bool isMultiSelectable() const override { return boolAttributeValue(AXPropertyName::IsMultiSelectable); }
+    bool isVisited() const override { return boolAttributeValue(AXPropertyName::IsVisited); }
+    bool isRequired() const override { return boolAttributeValue(AXPropertyName::IsRequired); }
+    bool supportsRequiredAttribute() const override { return boolAttributeValue(AXPropertyName::SupportsRequiredAttribute); }
+    bool isExpanded() const override { return boolAttributeValue(AXPropertyName::IsExpanded); }
+    FloatRect relativeFrame() const override { return rectAttributeValue<FloatRect>(AXPropertyName::RelativeFrame); }
+    bool supportsDatetimeAttribute() const override { return boolAttributeValue(AXPropertyName::SupportsDatetimeAttribute); }
+    String datetimeAttributeValue() const override { return stringAttributeValue(AXPropertyName::DatetimeAttributeValue); }
+    bool canSetFocusAttribute() const override { return boolAttributeValue(AXPropertyName::CanSetFocusAttribute); }
+    bool canSetTextRangeAttributes() const override { return boolAttributeValue(AXPropertyName::CanSetTextRangeAttributes); }
+    bool canSetValueAttribute() const override { return boolAttributeValue(AXPropertyName::CanSetValueAttribute); }
+    bool canSetNumericValue() const override { return boolAttributeValue(AXPropertyName::CanSetNumericValue); }
+    bool canSetSelectedAttribute() const override { return boolAttributeValue(AXPropertyName::CanSetSelectedAttribute); }
+    bool canSetSelectedChildrenAttribute() const override { return boolAttributeValue(AXPropertyName::CanSetSelectedChildrenAttribute); }
+    bool canSetExpandedAttribute() const override { return boolAttributeValue(AXPropertyName::CanSetExpandedAttribute); }
+    bool accessibilityIsIgnored() const override { return boolAttributeValue(AXPropertyName::IsAccessibilityIgnored); }
+    bool isShowingValidationMessage() const override { return boolAttributeValue(AXPropertyName::IsShowingValidationMessage); }
+    String validationMessage() const override { return stringAttributeValue(AXPropertyName::ValidationMessage); }
+    unsigned blockquoteLevel() const override { return unsignedAttributeValue(AXPropertyName::BlockquoteLevel); }
+    int headingLevel() const override { return intAttributeValue(AXPropertyName::HeadingLevel); }
+    int tableLevel() const override { return intAttributeValue(AXPropertyName::TableLevel); }
+    AccessibilityButtonState checkboxOrRadioValue() const override { return static_cast<AccessibilityButtonState>(intAttributeValue(AXPropertyName::AccessibilityButtonState)); }
+    String valueDescription() const override { return stringAttributeValue(AXPropertyName::ValueDescription); }
+    float valueForRange() const override { return floatAttributeValue(AXPropertyName::ValueForRange); }
+    float maxValueForRange() const override { return floatAttributeValue(AXPropertyName::MaxValueForRange); }
+    float minValueForRange() const override { return floatAttributeValue(AXPropertyName::MinValueForRange); }
+    AXCoreObject* selectedRadioButton() override { return objectAttributeValue(AXPropertyName::SelectedRadioButton); }
+    AXCoreObject* selectedTabItem() override { return objectAttributeValue(AXPropertyName::SelectedTabItem); }
+    int layoutCount() const override { return intAttributeValue(AXPropertyName::LayoutCount); }
+    double estimatedLoadingProgress() const override { return doubleAttributeValue(AXPropertyName::EstimatedLoadingProgress); }
+    bool supportsARIAOwns() const override { return boolAttributeValue(AXPropertyName::SupportsARIAOwns); }
+    bool isActiveDescendantOfFocusedContainer() const override { return boolAttributeValue(AXPropertyName::IsActiveDescendantOfFocusedContainer); }
+    void ariaControlsElements(AccessibilityChildrenVector& children) const override { fillChildrenVectorForProperty(AXPropertyName::ARIAControlsElements, children); }
+    void ariaDetailsElements(AccessibilityChildrenVector& children) const override { fillChildrenVectorForProperty(AXPropertyName::ARIADetailsElements, children); }
+    void ariaErrorMessageElements(AccessibilityChildrenVector& children) const override { fillChildrenVectorForProperty(AXPropertyName::ARIAErrorMessageElements, children); }
+    void ariaFlowToElements(AccessibilityChildrenVector& children) const override { fillChildrenVectorForProperty(AXPropertyName::ARIAFlowToElements, children); }
+    void ariaOwnsElements(AccessibilityChildrenVector& children) const override { fillChildrenVectorForProperty(AXPropertyName::ARIAOwnsElements, children); }
+    bool hasPopup() const override { return boolAttributeValue(AXPropertyName::HasPopup); }
+    String popupValue() const override { return stringAttributeValue(AXPropertyName::PopupValue); }
+    bool pressedIsPresent() const override { return boolAttributeValue(AXPropertyName::PressedIsPresent); }
+    bool ariaIsMultiline() const override { return boolAttributeValue(AXPropertyName::ARIAIsMultiline); }
+    String invalidStatus() const override { return stringAttributeValue(AXPropertyName::InvalidStatus); }
+    bool supportsExpanded() const override { return boolAttributeValue(AXPropertyName::SupportsExpanded); }
+    AccessibilitySortDirection sortDirection() const override { return static_cast<AccessibilitySortDirection>(intAttributeValue(AXPropertyName::SortDirection)); }
+    bool canvasHasFallbackContent() const override { return boolAttributeValue(AXPropertyName::CanvasHasFallbackContent); }
+    bool supportsRangeValue() const override { return boolAttributeValue(AXPropertyName::SupportsRangeValue); }
+    String identifierAttribute() const override { return stringAttributeValue(AXPropertyName::IdentifierAttribute); }
+    String linkRelValue() const override { return stringAttributeValue(AXPropertyName::LinkRelValue); }
+    void classList(Vector<String>&) const override;
+    AccessibilityCurrentState currentState() const override { return static_cast<AccessibilityCurrentState>(intAttributeValue(AXPropertyName::CurrentState)); }
+    String currentValue() const override { return stringAttributeValue(AXPropertyName::CurrentValue); }
+    bool supportsCurrent() const override { return boolAttributeValue(AXPropertyName::SupportsCurrent); }
+    const String keyShortcutsValue() const override { return stringAttributeValue(AXPropertyName::KeyShortcutsValue); }
+    bool supportsSetSize() const override { return boolAttributeValue(AXPropertyName::SupportsSetSize); }
+    bool supportsPosInSet() const override { return boolAttributeValue(AXPropertyName::SupportsPosInSet); }
+    int setSize() const override { return intAttributeValue(AXPropertyName::SetSize); }
+    int posInSet() const override { return intAttributeValue(AXPropertyName::PosInSet); }
+    bool supportsARIADropping() const override { return boolAttributeValue(AXPropertyName::SupportsARIADropping); }
+    bool supportsARIADragging() const override { return boolAttributeValue(AXPropertyName::SupportsARIADragging); }
+    bool isARIAGrabbed() override { return boolAttributeValue(AXPropertyName::IsARIAGrabbed); }
+    Vector<String> determineARIADropEffects() override { return vectorAttributeValue<String>(AXPropertyName::ARIADropEffects); }
+    AXCoreObject* accessibilityHitTest(const IntPoint&) const override;
+    AXCoreObject* focusedUIElement() const override;
+    AXCoreObject* parentObject() const override { return parentObjectUnignored(); }
+    AXCoreObject* parentObjectUnignored() const override;
+    void linkedUIElements(AccessibilityChildrenVector& children) const override { fillChildrenVectorForProperty(AXPropertyName::LinkedUIElements, children); }
+    AXCoreObject* titleUIElement() const override { return objectAttributeValue(AXPropertyName::TitleUIElement); }
+    bool exposesTitleUIElement() const override { return boolAttributeValue(AXPropertyName::ExposesTitleUIElement); }
+    AXCoreObject* scrollBar(AccessibilityOrientation) override;
+    AccessibilityRole ariaRoleAttribute() const override { return static_cast<AccessibilityRole>(intAttributeValue(AXPropertyName::ARIARoleAttribute)); }
+    String computedLabel() override { return stringAttributeValue(AXPropertyName::ComputedLabel); }
+    int textLength() const override { return intAttributeValue(AXPropertyName::TextLength); }
+    const String placeholderValue() const override { return stringAttributeValue(AXPropertyName::PlaceholderValue); }
+    String expandedTextValue() const override { return stringAttributeValue(AXPropertyName::ExpandedTextValue); }
+    bool supportsExpandedTextValue() const override { return boolAttributeValue(AXPropertyName::SupportsExpandedTextValue); }
+    void colorValue(int&, int&, int&) const override;
+    AccessibilityRole roleValue() const override { return static_cast<AccessibilityRole>(intAttributeValue(AXPropertyName::RoleValue)); }
+    String rolePlatformString() const override { return stringAttributeValue(AXPropertyName::RolePlatformString); }
+    String roleDescription() const override { return stringAttributeValue(AXPropertyName::RoleDescription); }
+    String ariaLandmarkRoleDescription() const override { return stringAttributeValue(AXPropertyName::ARIALandmarkRoleDescription); }
+    bool supportsPressAction() const override { return boolAttributeValue(AXPropertyName::SupportsPressAction); }
+    LayoutRect boundingBoxRect() const override { return rectAttributeValue<LayoutRect>(AXPropertyName::BoundingBoxRect); }
+    LayoutRect elementRect() const override { return rectAttributeValue<LayoutRect>(AXPropertyName::ElementRect); }
+    IntPoint clickPoint() override { return intPointAttributeValue(AXPropertyName::ClickPoint); }
+    void accessibilityText(Vector<AccessibilityText>& texts) const override;
+    String computedRoleString() const override { return stringAttributeValue(AXPropertyName::ComputedRoleString); }
+    bool isValueAutofilled() const override { return boolAttributeValue(AXPropertyName::IsValueAutofilled); }
+    bool isValueAutofillAvailable() const override { return boolAttributeValue(AXPropertyName::IsValueAutofillAvailable); }
+    AutoFillButtonType valueAutofillButtonType() const override { return static_cast<AutoFillButtonType>(intAttributeValue(AXPropertyName::ValueAutofillButtonType)); }
+    void ariaTreeRows(AccessibilityChildrenVector& children) override { fillChildrenVectorForProperty(AXPropertyName::ARIATreeRows, children); }
+    void ariaTreeItemDisclosedRows(AccessibilityChildrenVector& children) override { fillChildrenVectorForProperty(AXPropertyName::ARIATreeItemDisclosedRows, children); }
+    void ariaTreeItemContent(AccessibilityChildrenVector& children) override { fillChildrenVectorForProperty(AXPropertyName::ARIATreeItemContent, children); }
+    URL url() const override { return urlAttributeValue(AXPropertyName::URL); }
+    String accessKey() const override { return stringAttributeValue(AXPropertyName::AccessKey); }
+    String actionVerb() const override { return stringAttributeValue(AXPropertyName::ActionVerb); }
+    String readOnlyValue() const override { return stringAttributeValue(AXPropertyName::ReadOnlyValue); }
+    String autoCompleteValue() const override { return stringAttributeValue(AXPropertyName::AutoCompleteValue); }
+    OptionSet<SpeakAs> speakAsProperty() const override { return optionSetAttributeValue<SpeakAs>(AXPropertyName::SpeakAs); }
+    bool isMathElement() const override { return boolAttributeValue(AXPropertyName::IsMathElement); }
+    bool isMathFraction() const override { return boolAttributeValue(AXPropertyName::IsMathFraction); }
+    bool isMathFenced() const override { return boolAttributeValue(AXPropertyName::IsMathFenced); }
+    bool isMathSubscriptSuperscript() const override { return boolAttributeValue(AXPropertyName::IsMathSubscriptSuperscript); }
+    bool isMathRow() const override { return boolAttributeValue(AXPropertyName::IsMathRow); }
+    bool isMathUnderOver() const override { return boolAttributeValue(AXPropertyName::IsMathUnderOver); }
+    bool isMathRoot() const override { return boolAttributeValue(AXPropertyName::IsMathRoot); }
+    bool isMathSquareRoot() const override { return boolAttributeValue(AXPropertyName::IsMathSquareRoot); }
+    bool isMathText() const override { return boolAttributeValue(AXPropertyName::IsMathText); }
+    bool isMathNumber() const override { return boolAttributeValue(AXPropertyName::IsMathNumber); }
+    bool isMathOperator() const override { return boolAttributeValue(AXPropertyName::IsMathOperator); }
+    bool isMathFenceOperator() const override { return boolAttributeValue(AXPropertyName::IsMathFenceOperator); }
+    bool isMathSeparatorOperator() const override { return boolAttributeValue(AXPropertyName::IsMathSeparatorOperator); }
+    bool isMathIdentifier() const override { return boolAttributeValue(AXPropertyName::IsMathIdentifier); }
+    bool isMathTable() const override { return boolAttributeValue(AXPropertyName::IsMathTable); }
+    bool isMathTableRow() const override { return boolAttributeValue(AXPropertyName::IsMathTableRow); }
+    bool isMathTableCell() const override { return boolAttributeValue(AXPropertyName::IsMathTableCell); }
+    bool isMathMultiscript() const override { return boolAttributeValue(AXPropertyName::IsMathMultiscript); }
+    bool isMathToken() const override { return boolAttributeValue(AXPropertyName::IsMathToken); }
+    AXCoreObject* mathRadicandObject() override { return objectAttributeValue(AXPropertyName::MathRadicandObject); }
+    AXCoreObject* mathRootIndexObject() override { return objectAttributeValue(AXPropertyName::MathRootIndexObject); }
+    AXCoreObject* mathUnderObject() override { return objectAttributeValue(AXPropertyName::MathUnderObject); }
+    AXCoreObject* mathOverObject() override { return objectAttributeValue(AXPropertyName::MathOverObject); }
+    AXCoreObject* mathNumeratorObject() override { return objectAttributeValue(AXPropertyName::MathNumeratorObject); }
+    AXCoreObject* mathDenominatorObject() override { return objectAttributeValue(AXPropertyName::MathDenominatorObject); }
+    AXCoreObject* mathBaseObject() override { return objectAttributeValue(AXPropertyName::MathBaseObject); }
+    AXCoreObject* mathSubscriptObject() override { return objectAttributeValue(AXPropertyName::MathSubscriptObject); }
+    AXCoreObject* mathSuperscriptObject() override { return objectAttributeValue(AXPropertyName::MathSuperscriptObject); }
+    String mathFencedOpenString() const override { return stringAttributeValue(AXPropertyName::MathFencedOpenString); }
+    String mathFencedCloseString() const override { return stringAttributeValue(AXPropertyName::MathFencedCloseString); }
+    int mathLineThickness() const override { return intAttributeValue(AXPropertyName::MathLineThickness); }
+    bool isAnonymousMathOperator() const override { return boolAttributeValue(AXPropertyName::IsAnonymousMathOperator); }
+    void mathPrescripts(AccessibilityMathMultiscriptPairs&) override;
+    void mathPostscripts(AccessibilityMathMultiscriptPairs&) override;
+    bool fileUploadButtonReturnsValueInTitle() const override { return boolAttributeValue(AXPropertyName::FileUploadButtonReturnsValueInTitle); }
+    String speechHintAttributeValue() const override { return stringAttributeValue(AXPropertyName::SpeechHint); }
+    String descriptionAttributeValue() const override { return stringAttributeValue(AXPropertyName::Description); }
+    String helpTextAttributeValue() const override { return stringAttributeValue(AXPropertyName::HelpText); }
+    String titleAttributeValue() const override { return stringAttributeValue(AXPropertyName::Title); }
+    bool caretBrowsingEnabled() const override { return boolAttributeValue(AXPropertyName::CaretBrowsingEnabled); }
+    AXCoreObject* focusableAncestor() override { return objectAttributeValue(AXPropertyName::FocusableAncestor); }
+    AXCoreObject* editableAncestor() override { return objectAttributeValue(AXPropertyName::EditableAncestor); }
+    AXCoreObject* highestEditableAncestor() override { return objectAttributeValue(AXPropertyName::HighestEditableAncestor); }
+    AccessibilityOrientation orientation() const override { return static_cast<AccessibilityOrientation>(intAttributeValue(AXPropertyName::Orientation)); }
+    unsigned hierarchicalLevel() const override { return unsignedAttributeValue(AXPropertyName::HierarchicalLevel); }
+    String language() const override { return stringAttributeValue(AXPropertyName::Language); }
+    bool canHaveSelectedChildren() const override { return boolAttributeValue(AXPropertyName::CanHaveSelectedChildren); }
+    void selectedChildren(AccessibilityChildrenVector& children) override { fillChildrenVectorForProperty(AXPropertyName::SelectedChildren, children); }
+    void visibleChildren(AccessibilityChildrenVector& children) override { fillChildrenVectorForProperty(AXPropertyName::VisibleChildren, children); }
+    void tabChildren(AccessibilityChildrenVector& children) override { fillChildrenVectorForProperty(AXPropertyName::TabChildren, children); }
+    bool hasARIAValueNow() const override { return boolAttributeValue(AXPropertyName::HasARIAValueNow); }
+    String tagName() const override { return stringAttributeValue(AXPropertyName::TagName); }
+    const AccessibilityChildrenVector& children(bool updateChildrenIfNeeded = true) override;
+    void updateChildrenIfNecessary() override { }
+    bool isDetachedFromParent() override;
+    bool supportsLiveRegion(bool = true) const override { return boolAttributeValue(AXPropertyName::SupportsLiveRegion); }
+    bool isInsideLiveRegion(bool = true) const override { return boolAttributeValue(AXPropertyName::IsInsideLiveRegion); }
+    const String liveRegionStatus() const override { return stringAttributeValue(AXPropertyName::LiveRegionStatus); }
+    const String liveRegionRelevant() const override { return stringAttributeValue(AXPropertyName::LiveRegionRelevant); }
+    bool liveRegionAtomic() const override { return boolAttributeValue(AXPropertyName::LiveRegionAtomic); }
+    bool isBusy() const override { return boolAttributeValue(AXPropertyName::IsBusy); }
+    bool isInlineText() const override { return boolAttributeValue(AXPropertyName::IsInlineText); }
+
+    // Attributes retrieved from the root node only so that the data isn't duplicated on each node.
+    uint64_t sessionID() const override;
+    String documentURI() const override;
+    String documentEncoding() const override;
+    bool preventKeyboardDOMEventDispatch() const override;
+
+    // TODO: Text ranges and selection.
+    PlainTextRange selectedTextRange() const override { return PlainTextRange(); }
+    unsigned selectionStart() const override { return 0; }
+    unsigned selectionEnd() const override { return 0; }
+    VisibleSelection selection() const override { return VisibleSelection(); }
+    String selectedText() const override { return String(); }
+    VisiblePositionRange visiblePositionRange() const override { return VisiblePositionRange(); }
+    VisiblePositionRange visiblePositionRangeForLine(unsigned) const override { return VisiblePositionRange(); }
+    RefPtr<Range> elementRange() const override { return nullptr; }
+    VisiblePositionRange visiblePositionRangeForUnorderedPositions(const VisiblePosition&, const VisiblePosition&) const override { return VisiblePositionRange(); }
+    VisiblePositionRange positionOfLeftWord(const VisiblePosition&) const override { return VisiblePositionRange(); }
+    VisiblePositionRange positionOfRightWord(const VisiblePosition&) const override { return VisiblePositionRange(); }
+    VisiblePositionRange leftLineVisiblePositionRange(const VisiblePosition&) const override { return VisiblePositionRange(); }
+    VisiblePositionRange rightLineVisiblePositionRange(const VisiblePosition&) const override { return VisiblePositionRange(); }
+    VisiblePositionRange sentenceForPosition(const VisiblePosition&) const override { return VisiblePositionRange(); }
+    VisiblePositionRange paragraphForPosition(const VisiblePosition&) const override { return VisiblePositionRange(); }
+    VisiblePositionRange styleRangeForPosition(const VisiblePosition&) const override { return VisiblePositionRange(); }
+    VisiblePositionRange visiblePositionRangeForRange(const PlainTextRange&) const override { return VisiblePositionRange(); }
+    VisiblePositionRange lineRangeForPosition(const VisiblePosition&) const override { return VisiblePositionRange(); }
+    RefPtr<Range> rangeForPlainTextRange(const PlainTextRange&) const override { return nullptr; }
+    String stringForRange(RefPtr<Range>) const override { return String(); }
+    IntRect boundsForVisiblePositionRange(const VisiblePositionRange&) const override { return IntRect(); }
+    IntRect boundsForRange(const RefPtr<Range>) const override { return IntRect(); }
+    int lengthForVisiblePositionRange(const VisiblePositionRange&) const override { return 0; }
+    void setSelectedVisiblePositionRange(const VisiblePositionRange&) const override { }
+    VisiblePosition visiblePositionForBounds(const IntRect&, AccessibilityVisiblePositionForBounds) const override { return VisiblePosition(); }
+    VisiblePosition visiblePositionForPoint(const IntPoint&) const override { return VisiblePosition(); }
+    VisiblePosition nextVisiblePosition(const VisiblePosition&) const override { return VisiblePosition(); }
+    VisiblePosition previousVisiblePosition(const VisiblePosition&) const override { return VisiblePosition(); }
+    VisiblePosition nextWordEnd(const VisiblePosition&) const override { return VisiblePosition(); }
+    VisiblePosition previousWordStart(const VisiblePosition&) const override { return VisiblePosition(); }
+    VisiblePosition nextLineEndPosition(const VisiblePosition&) const override { return VisiblePosition(); }
+    VisiblePosition previousLineStartPosition(const VisiblePosition&) const override { return VisiblePosition(); }
+    VisiblePosition nextSentenceEndPosition(const VisiblePosition&) const override { return VisiblePosition(); }
+    VisiblePosition previousSentenceStartPosition(const VisiblePosition&) const override { return VisiblePosition(); }
+    VisiblePosition nextParagraphEndPosition(const VisiblePosition&) const override { return VisiblePosition(); }
+    VisiblePosition previousParagraphStartPosition(const VisiblePosition&) const override { return VisiblePosition(); }
+    VisiblePosition visiblePositionForIndex(unsigned, bool /*lastIndexOK */) const override { return VisiblePosition(); }
+    VisiblePosition visiblePositionForIndex(int) const override { return VisiblePosition(); }
+    int indexForVisiblePosition(const VisiblePosition&) const override { return 0; }
+    AXCoreObject* accessibilityObjectForPosition(const VisiblePosition&) const override { return nullptr; }
+    int lineForPosition(const VisiblePosition&) const override { return 0; }
+    PlainTextRange plainTextRangeForVisiblePositionRange(const VisiblePositionRange&) const override { return PlainTextRange(); }
+    int index(const VisiblePosition&) const override { return 0; }
+    void lineBreaks(Vector<int>&) const override { }
+    PlainTextRange doAXRangeForLine(unsigned) const override { return PlainTextRange(); }
+    PlainTextRange doAXRangeForPosition(const IntPoint&) const override { return PlainTextRange(); }
+    PlainTextRange doAXRangeForIndex(unsigned) const override { return PlainTextRange(); }
+    PlainTextRange doAXStyleRangeForIndex(unsigned) const override { return PlainTextRange(); }
+    String doAXStringForRange(const PlainTextRange&) const override { return String(); }
+    IntRect doAXBoundsForRange(const PlainTextRange&) const override { return IntRect(); }
+    IntRect doAXBoundsForRangeUsingCharacterOffset(const PlainTextRange&) const override { return IntRect(); }
+    unsigned doAXLineForIndex(unsigned) override { return 0; }
+
+    // TODO: Attribute setters.
+    void setARIAGrabbed(bool) override { }
+    void setIsExpanded(bool) override { }
+    void setValue(float) override { }
+    void setSelected(bool) override { }
+    void setSelectedRows(AccessibilityChildrenVector&) override { }
+    void setFocused(bool) override { }
+    void setSelectedText(const String&) override { }
+    void setSelectedTextRange(const PlainTextRange&) override { }
+    void setValue(const String&) override { }
+    void setCaretBrowsingEnabled(bool) override { }
+    void setPreventKeyboardDOMEventDispatch(bool) override { }
+
+    // TODO: Functions
+    String textUnderElement(AccessibilityTextUnderElementMode = AccessibilityTextUnderElementMode()) const override { return String(); }
+    RefPtr<Range> getMisspellingRange(RefPtr<Range> const&, AccessibilitySearchDirection) const override { return nullptr; }
+    void findMatchingObjects(AccessibilitySearchCriteria*, AccessibilityChildrenVector&) override { }
+    Vector<RefPtr<Range>> findTextRanges(AccessibilitySearchTextCriteria const&) const override { return Vector<RefPtr<Range>>(); }
+    Vector<String> performTextOperation(AccessibilityTextOperation const&) override { return Vector<String>(); }
+    FloatRect convertFrameToSpace(const FloatRect&, AccessibilityConversionSpace) const override { return FloatRect(); }
+    void increment() override { }
+    void decrement() override { }
+    void scrollToMakeVisible() const override { }
+    void scrollToMakeVisibleWithSubFocus(const IntRect&) const override { }
+    void scrollToGlobalPoint(const IntPoint&) const override { }
+    bool replaceTextInRange(const String&, const PlainTextRange&) override;
+    bool insertText(const String&) override;
+    void makeRangeVisible(const PlainTextRange&) override { }
+    bool press() override;
+    bool performDefaultAction() override;
+
+    // Functions that should never be called on an isolated tree object. ASSERT that these are not reached;
+    bool isAccessibilityObject() const override;
+    bool isAccessibilityNodeObject() const override;
+    bool isAccessibilityRenderObject() const override;
+    bool isAccessibilityScrollbar() const override;
+    bool isAccessibilityScrollView() const override;
+    bool isAccessibilitySVGRoot() const override;
+    bool isAccessibilitySVGElement() const override;
+    bool containsText(String*) const override;
+    bool isAttachmentElement() const override;
+    bool isNativeImage() const override;
+    bool isImageButton() const override;
+    bool isContainedByPasswordField() const override;
+    AXCoreObject* passwordFieldOrContainingPasswordField() override;
+    bool isNativeTextControl() const override;
+    bool isNativeListBox() const override;
+    bool isListBoxOption() const override;
+    bool isSliderThumb() const override;
+    bool isInputSlider() const override;
+    bool isLabel() const override;
+    bool isDataTable() const override;
+    bool isImageMapLink() const override;
+    bool isNativeSpinButton() const override;
+    bool isSpinButtonPart() const override;
+    bool isMockObject() const override;
+    bool isMediaObject() const override;
+    bool isARIATextControl() const override;
+    bool isNonNativeTextControl() const override;
+    bool isBlockquote() const override;
+    bool isLandmark() const override;
+    bool isFigureElement() const override;
+    bool isKeyboardFocusable() const override;
+    bool isHovered() const override;
+    bool isIndeterminate() const override;
+    bool isLoaded() const override;
+    bool isOnScreen() const override;
+    bool isOffScreen() const override;
+    bool isPressed() const override;
+    bool isUnvisited() const override;
+    bool isLinked() const override;
+    bool isVisible() const override;
+    bool isCollapsed() const override;
+    bool isSelectedOptionActive() const override;
+    bool hasBoldFont() const override;
+    bool hasItalicFont() const override;
+    bool hasMisspelling() const override;
+    bool hasPlainText() const override;
+    bool hasSameFont(RenderObject*) const override;
+    bool hasSameFontColor(RenderObject*) const override;
+    bool hasSameStyle(RenderObject*) const override;
+    bool isStaticText() const override;
+    bool hasUnderline() const override;
+    bool hasHighlighting() const override;
+    Element* element() const override;
+    Node* node() const override;
+    RenderObject* renderer() const override;
+    AccessibilityObjectInclusion defaultObjectInclusion() const override;
+    bool accessibilityIsIgnoredByDefault() const override;
+    float stepValueForRange() const override;
+    AXCoreObject* selectedListItem() override;
+    void ariaActiveDescendantReferencingElements(AccessibilityChildrenVector&) const override;
+    void ariaControlsReferencingElements(AccessibilityChildrenVector&) const override;
+    void ariaDescribedByElements(AccessibilityChildrenVector&) const override;
+    void ariaDescribedByReferencingElements(AccessibilityChildrenVector&) const override;
+    void ariaDetailsReferencingElements(AccessibilityChildrenVector&) const override;
+    void ariaErrorMessageReferencingElements(AccessibilityChildrenVector&) const override;
+    void ariaFlowToReferencingElements(AccessibilityChildrenVector&) const override;
+    void ariaLabelledByElements(AccessibilityChildrenVector&) const override;
+    void ariaLabelledByReferencingElements(AccessibilityChildrenVector&) const override;
+    void ariaOwnsReferencingElements(AccessibilityChildrenVector&) const override;
+    bool hasDatalist() const override;
+    bool supportsHasPopup() const override;
+    bool supportsPressed() const override;
+    bool supportsChecked() const override;
+    bool ignoredFromModalPresence() const override;
+    bool isModalDescendant(Node*) const override;
+    bool isModalNode() const override;
+    AXCoreObject* elementAccessibilityHitTest(const IntPoint&) const override;
+    AXCoreObject* firstChild() const override;
+    AXCoreObject* lastChild() const override;
+    AXCoreObject* previousSibling() const override;
+    AXCoreObject* nextSibling() const override;
+    AXCoreObject* nextSiblingUnignored(int limit) const override;
+    AXCoreObject* previousSiblingUnignored(int limit) const override;
+    AXCoreObject* parentObjectIfExists() const override;
+    bool isDescendantOfBarrenParent() const override;
+    bool isDescendantOfRole(AccessibilityRole) const override;
+    AXCoreObject* observableObject() const override;
+    AXCoreObject* correspondingLabelForControlElement() const override;
+    AXCoreObject* correspondingControlForLabelElement() const override;
+    bool isPresentationalChildOfAriaRole() const override;
+    bool ariaRoleHasPresentationalChildren() const override;
+    bool inheritsPresentationalRole() const override;
+    void setAccessibleName(const AtomString&) override;
+    bool hasAttributesRequiredForInclusion() const override;
+    String accessibilityDescription() const override;
+    String title() const override;
+    String helpText() const override;
+    bool isARIAStaticText() const override;
+    String stringValue() const override;
+    String text() const override;
+    String ariaLabeledByAttribute() const override;
+    String ariaDescribedByAttribute() const override;
+    bool accessibleNameDerivesFromContent() const override;
+    void elementsFromAttribute(Vector<Element*>&, const QualifiedName&) const override;
+    AXObjectCache* axObjectCache() const override;
+    Element* anchorElement() const override;
+    Element* actionElement() const override;
+    Path elementPath() const override;
+    bool supportsPath() const override;
+    TextIteratorBehavior textIteratorBehaviorForTextRange() const override;
+    Widget* widget() const override;
+    Widget* widgetForAttachmentView() const override;
+    Page* page() const override;
+    Document* document() const override;
+    FrameView* documentFrameView() const override;
+    Frame* frame() const override;
+    Frame* mainFrame() const override;
+    Document* topDocument() const override;
+    ScrollView* scrollViewAncestor() const override;
+    void childrenChanged() override;
+    void textChanged() override;
+    void updateAccessibilityRole() override;
+    void addChildren() override;
+    void addChild(AXCoreObject*) override;
+    void insertChild(AXCoreObject*, unsigned) override;
+    bool shouldIgnoreAttributeRole() const override;
+    bool canHaveChildren() const override;
+    bool hasChildren() const override;
+    void setNeedsToUpdateChildren() override;
+    void setNeedsToUpdateSubtree() override;
+    void clearChildren() override;
+    bool needsToUpdateChildren() const override;
+    void detachFromParent() override;
+    bool shouldFocusActiveDescendant() const override;
+    AXCoreObject* activeDescendant() const override;
+    void handleActiveDescendantChanged() override;
+    void handleAriaExpandedChanged() override;
+    bool isDescendantOfObject(const AXCoreObject*) const override;
+    bool isAncestorOfObject(const AXCoreObject*) const override;
+    AXCoreObject* firstAnonymousBlockChild() const override;
+    bool hasAttribute(const QualifiedName&) const override;
+    const AtomString& getAttribute(const QualifiedName&) const override;
+    bool hasTagName(const QualifiedName&) const override;
+    String stringValueForMSAA() const override;
+    String stringRoleForMSAA() const override;
+    String nameForMSAA() const override;
+    String descriptionForMSAA() const override;
+    AccessibilityRole roleValueForMSAA() const override;
+    String passwordFieldValue() const override;
+    AXCoreObject* liveRegionAncestor(bool excludeIfOff = true) const override;
+    bool hasContentEditableAttributeSet() const override;
+    bool supportsReadOnly() const override;
+    bool supportsAutoComplete() const override;
+    bool supportsARIAAttributes() const override;
+    bool scrollByPage(ScrollByPageDirection) const override;
+    IntPoint scrollPosition() const override;
+    IntSize scrollContentsSize() const override;
+    IntRect scrollVisibleContentRect() const override;
+    void scrollToMakeVisible(const ScrollRectToVisibleOptions&) const override;
+    bool lastKnownIsIgnoredValue() override;
+    void setLastKnownIsIgnoredValue(bool) override;
+    void notifyIfIgnoredValueChanged() override;
+    bool isMathScriptObject(AccessibilityMathScriptObjectType) const override;
+    bool isMathMultiscriptObject(AccessibilityMathMultiscriptObjectType) const override;
+    bool isAXHidden() const override;
+    bool isDOMHidden() const override;
+    bool isHidden() const override;
+    void overrideAttachmentParent(AXCoreObject* parent) override;
+    bool accessibilityIgnoreAttachment() const override;
+    AccessibilityObjectInclusion accessibilityPlatformIncludesObject() const override;
+    bool hasApplePDFAnnotationAttribute() const override;
+    const AccessibilityScrollView* ancestorAccessibilityScrollView(bool includeSelf) const override;
+    void setIsIgnoredFromParentData(AccessibilityIsIgnoredFromParentData&) override;
+    void clearIsIgnoredFromParentData() override;
+    void setIsIgnoredFromParentDataForChild(AXCoreObject*) override;
+
+    void updateBackingStore() override;
+    void setWrapper(AccessibilityObjectWrapper* wrapper) override { m_wrapper = wrapper; }
+    
     AXID m_parent;
     AXID m_id;
     bool m_initialized { false };
index 83b8543..66932d4 100644 (file)
@@ -555,13 +555,38 @@ extern "C" AXUIElementRef NSAccessibilityCreateAXUIElementRef(id element);
     [super detach];
 }
 
+template<typename U> inline void performAccessibilityFunctionOnMainThread(U&& lambda)
+{
+    if (isMainThread())
+        return lambda();
+
+    callOnMainThread([&lambda] {
+        lambda();
+    });
+}
+
+template<typename T, typename U> inline T retrieveAccessibilityValueFromMainThread(U&& lambda)
+{
+    if (isMainThread())
+        return lambda();
+    
+    T value;
+    callOnMainThreadAndWait([&value, &lambda] {
+        value = lambda();
+    });
+    return value;
+}
+
 - (id)attachmentView
 {
     ASSERT(m_object->isAttachment());
-    Widget* widget = m_object->widgetForAttachmentView();
-    if (!widget)
-        return nil;
-    return NSAccessibilityUnignoredDescendant(widget->platformWidget());
+
+    return retrieveAccessibilityValueFromMainThread<id>([protectedSelf = RetainPtr<WebAccessibilityObjectWrapper>(self)] () -> id {
+        auto* widget = protectedSelf->m_object->widgetForAttachmentView();
+        if (!widget)
+            return nil;
+        return NSAccessibilityUnignoredDescendant(widget->platformWidget());
+    });
 }
 
 #pragma mark SystemInterface wrappers
@@ -603,7 +628,9 @@ static id AXTextMarkerRangeEnd(id range)
 
 - (IntRect)screenToContents:(const IntRect&)rect
 {
-    Document* document = m_object->document();
+    ASSERT(isMainThread());
+
+    Document* document = _axBackingObject->document();
     if (!document)
         return IntRect();
     
@@ -1893,28 +1920,28 @@ ALLOW_DEPRECATED_IMPLEMENTATIONS_END
 
 - (NSArray*)renderWidgetChildren
 {
-    Widget* widget = m_object->widget();
-    if (!widget)
-        return nil;
-    ALLOW_DEPRECATED_DECLARATIONS_BEGIN
-    return [(widget->platformWidget()) accessibilityAttributeValue: NSAccessibilityChildrenAttribute];
-    ALLOW_DEPRECATED_DECLARATIONS_END
+    return retrieveAccessibilityValueFromMainThread<NSArray *>([protectedSelf = RetainPtr<WebAccessibilityObjectWrapper>(self)] () -> NSArray * {
+        Widget* widget = protectedSelf->m_object->widget();
+        if (!widget)
+            return nil;
+        ALLOW_DEPRECATED_DECLARATIONS_BEGIN
+        return [(widget->platformWidget()) accessibilityAttributeValue:NSAccessibilityChildrenAttribute];
+        ALLOW_DEPRECATED_DECLARATIONS_END
+    });
 }
 
 - (id)remoteAccessibilityParentObject
 {
+    ASSERT(isMainThread());
     if (!m_object)
         return nil;
-    
-    Document* document = m_object->document();
-    if (!document)
-        return nil;
-    
-    Frame* frame = document->frame();
-    if (!frame)
-        return nil;
-    
-    return frame->loader().client().accessibilityRemoteObject();
+
+    if (auto* document = _axBackingObject->document()) {
+        if (auto* frame = document->frame())
+            return frame->loader().client().accessibilityRemoteObject();
+    }
+
+    return nil;
 }
 
 static void convertToVector(NSArray* array, AccessibilityObject::AccessibilityChildrenVector& vector)
@@ -1946,17 +1973,19 @@ static NSMutableArray *convertStringsToNSArray(const Vector<String>& vector)
 
 - (id)associatedPluginParent
 {
-    if (!m_object || !m_object->hasAttribute(x_apple_pdf_annotationAttr))
-        return nil;
+    return retrieveAccessibilityValueFromMainThread<id>([protectedSelf = RetainPtr<WebAccessibilityObjectWrapper>(self)] () -> id {
+        if (!protectedSelf->m_object || !protectedSelf->m_object->hasApplePDFAnnotationAttribute())
+            return nil;
     
-    if (!m_object->document()->isPluginDocument())
-        return nil;
+        if (!protectedSelf->m_object->document()->isPluginDocument())
+            return nil;
         
-    Widget* pluginWidget = static_cast<PluginDocument*>(m_object->document())->pluginWidget();
-    if (!pluginWidget || !pluginWidget->isPluginViewBase())
-        return nil;
-
-    return static_cast<PluginViewBase*>(pluginWidget)->accessibilityAssociatedPluginParentForElement(m_object->element());
+        Widget* pluginWidget = static_cast<PluginDocument*>(protectedSelf->m_object->document())->pluginWidget();
+        if (!pluginWidget || !pluginWidget->isPluginViewBase())
+            return nil;
+        
+        return static_cast<PluginViewBase*>(pluginWidget)->accessibilityAssociatedPluginParentForElement(protectedSelf->m_object->element());
+    });
 }
 
 static void WebTransformCGPathToNSBezierPath(void* info, const CGPathElement *element)
@@ -2220,20 +2249,20 @@ ALLOW_DEPRECATED_DECLARATIONS_BEGIN
         return @"AXSubscriptStyleGroup";
 
     if (m_object->isStyleFormatGroup()) {
-        if (Node* node = m_object->node()) {
-            if (node->hasTagName(kbdTag))
-                return @"AXKeyboardInputStyleGroup";
-            if (node->hasTagName(codeTag))
-                return @"AXCodeStyleGroup";
-            if (node->hasTagName(preTag))
-                return @"AXPreformattedStyleGroup";
-            if (node->hasTagName(sampTag))
-                return @"AXSampleStyleGroup";
-            if (node->hasTagName(varTag))
-                return @"AXVariableStyleGroup";
-            if (node->hasTagName(citeTag))
-                return @"AXCiteStyleGroup";
-        }
+        auto tagName = m_object->tagName();
+        if (tagName == kbdTag)
+            return @"AXKeyboardInputStyleGroup";
+        if (tagName == codeTag)
+            return @"AXCodeStyleGroup";
+        if (tagName == preTag)
+            return @"AXPreformattedStyleGroup";
+        if (tagName == sampTag)
+            return @"AXSampleStyleGroup";
+        if (tagName == varTag)
+            return @"AXVariableStyleGroup";
+        if (tagName == citeTag)
+            return @"AXCiteStyleGroup";
+        ASSERT_NOT_REACHED();
     }
     
     // Ruby subroles
@@ -2297,22 +2326,24 @@ ALLOW_DEPRECATED_DECLARATIONS_END
 
 - (id)scrollViewParent
 {
-    if (!is<AccessibilityScrollView>(m_object))
-        return nil;
-    
-    // If this scroll view provides it's parent object (because it's a sub-frame), then
-    // we should not find the remoteAccessibilityParent.
-    if (m_object->parentObject())
-        return nil;
-    
-    ScrollView* scroll = downcast<AccessibilityScrollView>(*m_object).scrollView();
-    if (!scroll)
-        return nil;
-    
-    if (scroll->platformWidget())
-        return NSAccessibilityUnignoredAncestor(scroll->platformWidget());
-    
-    return [self remoteAccessibilityParentObject];
+    return retrieveAccessibilityValueFromMainThread<id>([protectedSelf = RetainPtr<WebAccessibilityObjectWrapper>(self)] () -> id {
+        if (!is<AccessibilityScrollView>(protectedSelf->m_object))
+            return nil;
+
+        // If this scroll view provides it's parent object (because it's a sub-frame), then
+        // we should not find the remoteAccessibilityParent.
+        if (protectedSelf->m_object->parentObject())
+            return nil;
+
+        ScrollView* scroll = downcast<AccessibilityScrollView>(*protectedSelf->m_object).scrollView();
+        if (!scroll)
+            return nil;
+
+        if (scroll->platformWidget())
+            return NSAccessibilityUnignoredAncestor(scroll->platformWidget());
+
+        return [protectedSelf remoteAccessibilityParentObject];
+    });
 }
 
 - (NSString *)valueDescriptionForMeter
@@ -2338,6 +2369,23 @@ ALLOW_DEPRECATED_DECLARATIONS_END
     return valueDescription;
 }
 
+- (id)windowElement:(NSString*)attributeName
+{
+    return retrieveAccessibilityValueFromMainThread<id>([attributeName, protectedSelf = RetainPtr<WebAccessibilityObjectWrapper>(self)] () -> id {
+        id remoteParent = [protectedSelf remoteAccessibilityParentObject];
+        if (remoteParent) {
+            ALLOW_DEPRECATED_DECLARATIONS_BEGIN
+            return [remoteParent accessibilityAttributeValue:attributeName];
+            ALLOW_DEPRECATED_DECLARATIONS_END
+        }
+
+        if (auto* fv = protectedSelf->m_object->documentFrameView())
+            return [fv->platformWidget() window];
+
+        return nil;
+    });
+}
+
 // FIXME: split up this function in a better way.
 // suggestions: Use a hash table that maps attribute names to function calls,
 // or maybe pointers to member functions
@@ -2453,12 +2501,8 @@ ALLOW_DEPRECATED_IMPLEMENTATIONS_END
             return [NSNumber numberWithBool:m_object->preventKeyboardDOMEventDispatch()];
         if ([attributeName isEqualToString:NSAccessibilityCaretBrowsingEnabledAttribute])
             return [NSNumber numberWithBool:m_object->caretBrowsingEnabled()];
-        if ([attributeName isEqualToString:NSAccessibilityWebSessionIDAttribute]) {
-            if (auto* document = m_object->topDocument()) {
-                if (auto* page = document->page())
-                    return [NSNumber numberWithUnsignedLongLong:page->sessionID().toUInt64()];
-            }
-        }
+        if ([attributeName isEqualToString:NSAccessibilityWebSessionIDAttribute])
+            return @(m_object->sessionID());
     }
     
     if (m_object->isTextControl()) {
@@ -2599,14 +2643,14 @@ ALLOW_DEPRECATED_IMPLEMENTATIONS_END
     
     if ([attributeName isEqualToString: NSAccessibilityMinValueAttribute]) {
         // Indeterminate progress indicator should return 0.
-        if (m_object->ariaRoleAttribute() == AccessibilityRole::ProgressIndicator && !m_object->hasAttribute(aria_valuenowAttr))
+        if (m_object->ariaRoleAttribute() == AccessibilityRole::ProgressIndicator && !m_object->hasARIAValueNow())
             return @0;
         return [NSNumber numberWithFloat:m_object->minValueForRange()];
     }
     
     if ([attributeName isEqualToString: NSAccessibilityMaxValueAttribute]) {
         // Indeterminate progress indicator should return 0.
-        if (m_object->ariaRoleAttribute() == AccessibilityRole::ProgressIndicator && !m_object->hasAttribute(aria_valuenowAttr))
+        if (m_object->ariaRoleAttribute() == AccessibilityRole::ProgressIndicator && !m_object->hasARIAValueNow())
             return @0;
         return [NSNumber numberWithFloat:m_object->maxValueForRange()];
     }
@@ -2631,20 +2675,11 @@ ALLOW_DEPRECATED_IMPLEMENTATIONS_END
         return [self position];
     if ([attributeName isEqualToString:NSAccessibilityPathAttribute])
         return [self path];
-    
-    if ([attributeName isEqualToString: NSAccessibilityWindowAttribute] ||
-        [attributeName isEqualToString: NSAccessibilityTopLevelUIElementAttribute]) {
-        
-        id remoteParent = [self remoteAccessibilityParentObject];
-        if (remoteParent)
-            return [remoteParent accessibilityAttributeValue:attributeName];
-        
-        FrameView* fv = m_object->documentFrameView();
-        if (fv)
-            return [fv->platformWidget() window];
-        return nil;
-    }
-    
+
+    if ([attributeName isEqualToString:NSAccessibilityWindowAttribute]
+        || [attributeName isEqualToString:NSAccessibilityTopLevelUIElementAttribute])
+        return [self windowElement:attributeName];
+
     if ([attributeName isEqualToString:NSAccessibilityAccessKeyAttribute]) {
         AtomString accessKey = m_object->accessKey();
         if (accessKey.isNull())
@@ -2897,12 +2932,10 @@ ALLOW_DEPRECATED_IMPLEMENTATIONS_END
     if ([attributeName isEqualToString: @"AXSelectedTextMarkerRange"])
         return [self textMarkerRangeForSelection];
     
-    if (m_object->renderer()) {
-        if ([attributeName isEqualToString: @"AXStartTextMarker"])
-            return [self textMarkerForVisiblePosition:startOfDocument(&m_object->renderer()->document())];
-        if ([attributeName isEqualToString: @"AXEndTextMarker"])
-            return [self textMarkerForVisiblePosition:endOfDocument(&m_object->renderer()->document())];
-    }
+    if ([attributeName isEqualToString: @"AXStartTextMarker"])
+        return [self textMarkerForVisiblePosition:startOfDocument(_axBackingObject->document())];
+    if ([attributeName isEqualToString: @"AXEndTextMarker"])
+        return [self textMarkerForVisiblePosition:endOfDocument(_axBackingObject->document())];
     
     if ([attributeName isEqualToString:NSAccessibilityBlockQuoteLevelAttribute])
         return [NSNumber numberWithUnsignedInt:m_object->blockquoteLevel()];
@@ -3040,7 +3073,7 @@ ALLOW_DEPRECATED_IMPLEMENTATIONS_END
         return m_object->datetimeAttributeValue();
     
     if ([attributeName isEqualToString:NSAccessibilityInlineTextAttribute])
-        return @(m_object->renderer() && is<RenderInline>(m_object->renderer()));
+        return @(_axBackingObject->isInlineText());
     
     // ARIA Live region attributes.
     if ([attributeName isEqualToString:NSAccessibilityARIALiveAttribute])
@@ -3109,7 +3142,7 @@ ALLOW_DEPRECATED_IMPLEMENTATIONS_END
     
     // Used by DRT to find an accessible node by its element id.
     if ([attributeName isEqualToString:@"AXDRTElementIdAttribute"])
-        return m_object->getAttribute(idAttr);
+        return m_object->identifierAttribute();
     
     if ([attributeName isEqualToString:@"AXAutocompleteValue"])
         return m_object->autoCompleteValue();
@@ -3152,17 +3185,11 @@ ALLOW_DEPRECATED_IMPLEMENTATIONS_END
         return [NSNumber numberWithBool:m_object->isMultiSelectable()];
     
     // Document attributes
-    if ([attributeName isEqualToString:NSAccessibilityDocumentURIAttribute]) {
-        if (Document* document = m_object->document())
-            return document->documentURI();
-        return nil;
-    }
+    if ([attributeName isEqualToString:NSAccessibilityDocumentURIAttribute])
+        return m_object->documentURI();
     
-    if ([attributeName isEqualToString:NSAccessibilityDocumentEncodingAttribute]) {
-        if (Document* document = m_object->document())
-            return document->encoding();
-        return nil;
-    }
+    if ([attributeName isEqualToString:NSAccessibilityDocumentEncodingAttribute])
+        return m_object->documentEncoding();
     
     // Aria controls element
     if ([attributeName isEqualToString:NSAccessibilityAriaControlsAttribute]) {
@@ -3382,9 +3409,6 @@ ALLOW_DEPRECATED_IMPLEMENTATIONS_END
     if (m_object->isPasswordField())
         return @[ NSAccessibilityUIElementsForSearchPredicateParameterizedAttribute ];
     
-    if (!m_object->isAccessibilityRenderObject())
-        return paramAttrs;
-    
     if (m_object->isTextControl())
         return textParamAttrs;
     
@@ -3473,21 +3497,30 @@ ALLOW_DEPRECATED_DECLARATIONS_END
 
 - (void)accessibilityShowContextMenu
 {
-    if (!m_object)
+    performAccessibilityFunctionOnMainThread([protectedSelf = RetainPtr<WebAccessibilityObjectWrapper>(self)] {
+        [protectedSelf _accessibilityShowContextMenu];
+    });
+}
+
+- (void)_accessibilityShowContextMenu
+{
+    ASSERT(isMainThread());
+    
+    if (!_axBackingObject)
         return;
     
-    Page* page = m_object->page();
+    Page* page = _axBackingObject->page();
     if (!page)
         return;
     
-    IntRect rect = snappedIntRect(m_object->elementRect());
-    FrameView* frameView = m_object->documentFrameView();
+    IntRect rect = snappedIntRect(_axBackingObject->elementRect());
+    FrameView* frameView = _axBackingObject->documentFrameView();
     
     // On WK2, we need to account for the scroll position with regards to root view.
     // On WK1, we need to convert rect to window space to match mouse clicking.
     if (frameView) {
         // Find the appropriate scroll view to use to convert the contents to the window.
-        for (auto* parent = m_object->parentObject(); parent; parent = parent->parentObject()) {
+        for (auto* parent = _axBackingObject->parentObject(); parent; parent = parent->parentObject()) {
             if (is<AccessibilityScrollView>(*parent)) {
                 if (auto scrollView = downcast<AccessibilityScrollView>(*parent).scrollView()) {
                     if (!frameView->platformWidget())
@@ -3711,11 +3744,13 @@ ALLOW_DEPRECATED_IMPLEMENTATIONS_END
 
 - (NSRange)_convertToNSRange:(Range*)range
 {
+    ASSERT(isMainThread());
+    
     NSRange result = NSMakeRange(NSNotFound, 0);
     if (!range)
         return result;
     
-    Document* document = m_object->document();
+    Document* document = _axBackingObject->document();
     if (!document)
         return result;
     
@@ -3744,7 +3779,9 @@ ALLOW_DEPRECATED_IMPLEMENTATIONS_END
 
 - (id)_textMarkerForIndex:(NSInteger)textIndex
 {
-    Document* document = m_object->document();
+    ASSERT(isMainThread());
+
+    Document* document = _axBackingObject->document();
     if (!document)
         return nil;