AX: VoiceOver is not detecting ARIA treeview if it contains role="presentation"
authorn_wang@apple.com <n_wang@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 21 Oct 2016 01:15:21 +0000 (01:15 +0000)
committern_wang@apple.com <n_wang@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 21 Oct 2016 01:15:21 +0000 (01:15 +0000)
commitf4117b66e2fedf7350f252e85f414e80a98a92c8
tree646d2ac95330dd6aad784ba4d4f5529dde8a724f
parent7c03372ae76eff7dd9cde63d307d0070414ea0d8
AX: VoiceOver is not detecting ARIA treeview if it contains role="presentation"
https://bugs.webkit.org/show_bug.cgi?id=163763

Reviewed by Chris Fleizach.

Source/WebCore:

Test: accessibility/mac/aria-tree-with-presentation-role.html

Web authors sometimes use presentation role in the aria tree to hide elements. We should
consider this a valid case if they specify tree items and groups correctly.

* accessibility/AccessibilityNodeObject.cpp:
(WebCore::AccessibilityNodeObject::hierarchicalLevel):
* accessibility/AccessibilityTree.cpp:
(WebCore::AccessibilityTree::nodeHasTreeItemChild):
(WebCore::AccessibilityTree::isTreeValid):
* accessibility/AccessibilityTree.h:

LayoutTests:

* accessibility/mac/aria-tree-with-presentation-role-expected.txt: Added.
* accessibility/mac/aria-tree-with-presentation-role.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@207647 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/accessibility/mac/aria-tree-with-presentation-role-expected.txt [new file with mode: 0644]
LayoutTests/accessibility/mac/aria-tree-with-presentation-role.html [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/accessibility/AccessibilityNodeObject.cpp
Source/WebCore/accessibility/AccessibilityTree.cpp
Source/WebCore/accessibility/AccessibilityTree.h