AX: Expose DOM ID and ClassList to AX APIs for automation and AT element hashes
authorcfleizach@apple.com <cfleizach@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 10 Sep 2013 18:33:03 +0000 (18:33 +0000)
committercfleizach@apple.com <cfleizach@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 10 Sep 2013 18:33:03 +0000 (18:33 +0000)
commit440934ee44d0f806ee973878d3ddd9835de4c02e
tree49b53ddbd7ae0c3186a4d8f35a218e70b133c8e4
parent89dc61f91527e18bdfb396581dd53cc98fba6b52
AX: Expose DOM ID and ClassList to AX APIs for automation and AT element hashes
https://bugs.webkit.org/show_bug.cgi?id=120552

Reviewed by Darin Adler.

Source/WebCore:

Add Mac support for exposing the DOM ID and DOM class list so that accessibility
clients can leverage that information.

Test: platform/mac/accessibility/id-class-attributes.html

* accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::domIdentifier):
(WebCore::AccessibilityObject::domClassList):
* accessibility/AccessibilityObject.h:
* accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
(-[WebAccessibilityObjectWrapper accessibilityAttributeNames]):
(convertStringsToNSArray):
(-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):

Tools:

* DumpRenderTree/AccessibilityUIElement.cpp:
(getClassListCallback):
(AccessibilityUIElement::getJSClass):
* DumpRenderTree/AccessibilityUIElement.h:
* DumpRenderTree/atk/AccessibilityUIElementAtk.cpp:
(AccessibilityUIElement::classList):
* DumpRenderTree/blackberry/AccessibilityUIElementBlackBerry.cpp:
(AccessibilityUIElement::classList):
* DumpRenderTree/mac/AccessibilityUIElementMac.mm:
(AccessibilityUIElement::classList):
* DumpRenderTree/win/AccessibilityUIElementWin.cpp:
(AccessibilityUIElement::classList):
* WebKitTestRunner/InjectedBundle/AccessibilityUIElement.cpp:
(WTR::AccessibilityUIElement::classList):
* WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h:
* WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl:
* WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
(WTR::AccessibilityUIElement::classList):
* WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm:
(WTR::AccessibilityUIElement::classList):

LayoutTests:

Tests that output all attributes need to be updated, since the DOM ID and DOM
class list are new on all elements.

* accessibility/transformed-element-expected.txt:
* platform/mac/accessibility/aria-columnrowheaders-expected.txt:
* platform/mac/accessibility/bounds-for-range-expected.txt:
* platform/mac/accessibility/document-attributes-expected.txt:
* platform/mac/accessibility/document-links-expected.txt:
* platform/mac/accessibility/id-class-attributes-expected.txt: Added.
* platform/mac/accessibility/id-class-attributes.html: Added.
* platform/mac/accessibility/image-link-expected.txt:
* platform/mac/accessibility/image-map2-expected.txt:
* platform/mac/accessibility/internal-link-anchors-expected.txt:
* platform/mac/accessibility/internal-link-anchors2-expected.txt:
* platform/mac/accessibility/lists-expected.txt:
* platform/mac/accessibility/plugin-expected.txt:
* platform/mac/accessibility/radio-button-group-members-expected.txt:
* platform/mac/accessibility/table-attributes-expected.txt:
* platform/mac/accessibility/table-cell-spans-expected.txt:
* platform/mac/accessibility/table-cells-expected.txt:
* platform/mac/accessibility/table-detection-expected.txt:
* platform/mac/accessibility/table-one-cell-expected.txt:
* platform/mac/accessibility/table-sections-expected.txt:
* platform/mac/accessibility/table-with-aria-role-expected.txt:
* platform/mac/accessibility/table-with-rules-expected.txt:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@155458 268f45cc-cd09-0410-ab3c-d52691b4dbfc
39 files changed:
LayoutTests/ChangeLog
LayoutTests/accessibility/transformed-element-expected.txt
LayoutTests/platform/mac/accessibility/aria-columnrowheaders-expected.txt
LayoutTests/platform/mac/accessibility/bounds-for-range-expected.txt
LayoutTests/platform/mac/accessibility/document-attributes-expected.txt
LayoutTests/platform/mac/accessibility/document-links-expected.txt
LayoutTests/platform/mac/accessibility/id-class-attributes-expected.txt [new file with mode: 0644]
LayoutTests/platform/mac/accessibility/id-class-attributes.html [new file with mode: 0644]
LayoutTests/platform/mac/accessibility/image-link-expected.txt
LayoutTests/platform/mac/accessibility/image-map2-expected.txt
LayoutTests/platform/mac/accessibility/internal-link-anchors-expected.txt
LayoutTests/platform/mac/accessibility/internal-link-anchors2-expected.txt
LayoutTests/platform/mac/accessibility/lists-expected.txt
LayoutTests/platform/mac/accessibility/plugin-expected.txt
LayoutTests/platform/mac/accessibility/radio-button-group-members-expected.txt
LayoutTests/platform/mac/accessibility/table-attributes-expected.txt
LayoutTests/platform/mac/accessibility/table-cell-spans-expected.txt
LayoutTests/platform/mac/accessibility/table-cells-expected.txt
LayoutTests/platform/mac/accessibility/table-detection-expected.txt
LayoutTests/platform/mac/accessibility/table-one-cell-expected.txt
LayoutTests/platform/mac/accessibility/table-sections-expected.txt
LayoutTests/platform/mac/accessibility/table-with-aria-role-expected.txt
LayoutTests/platform/mac/accessibility/table-with-rules-expected.txt
Source/WebCore/ChangeLog
Source/WebCore/accessibility/AccessibilityObject.cpp
Source/WebCore/accessibility/AccessibilityObject.h
Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm
Tools/ChangeLog
Tools/DumpRenderTree/AccessibilityUIElement.cpp
Tools/DumpRenderTree/AccessibilityUIElement.h
Tools/DumpRenderTree/atk/AccessibilityUIElementAtk.cpp
Tools/DumpRenderTree/blackberry/AccessibilityUIElementBlackBerry.cpp
Tools/DumpRenderTree/mac/AccessibilityUIElementMac.mm
Tools/DumpRenderTree/win/AccessibilityUIElementWin.cpp
Tools/WebKitTestRunner/InjectedBundle/AccessibilityUIElement.cpp
Tools/WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h
Tools/WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl
Tools/WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp
Tools/WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm