Diff
Modified: trunk/LayoutTests/ChangeLog (284243 => 284244)
--- trunk/LayoutTests/ChangeLog 2021-10-15 14:01:05 UTC (rev 284243)
+++ trunk/LayoutTests/ChangeLog 2021-10-15 14:32:36 UTC (rev 284244)
@@ -1,3 +1,25 @@
+2021-10-15 Tyler Wilcock <[email protected]>
+
+ AX: Return AXEmptyGroup subrole for groups with no accessible content
+ https://bugs.webkit.org/show_bug.cgi?id=231528
+
+ Reviewed by Andres Gonzalez.
+
+ * accessibility/mac/aria-divs-not-ignored-expected.txt:
+ * accessibility/mac/aria-divs-not-ignored.html:
+ Expect a subrole of AXEmptyGroup because this group has no content.
+
+ * accessibility/mac/empty-group-computation-expected.txt: Added.
+ * accessibility/mac/empty-group-computation.html: Added.
+
+ * platform/mac/accessibility/lists-expected.txt: Added.
+ * platform/mac/accessibility/plugin-expected.txt: Added.
+ Add these Mac-specific expectations for these tests because this patch
+ only causes Mac to expose the AXEmptyGroup subrole.
+
+ * platform/mac/accessibility/svg-element-with-aria-role-expected.txt:
+ Add an expected subrole of AXEmptyGroup.
+
2021-10-15 Alan Bujtas <[email protected]>
[LFC][IFC] Do not break the word-wrap: break-word content on inline box boundary
Modified: trunk/LayoutTests/accessibility/mac/aria-divs-not-ignored-expected.txt (284243 => 284244)
--- trunk/LayoutTests/accessibility/mac/aria-divs-not-ignored-expected.txt 2021-10-15 14:01:05 UTC (rev 284243)
+++ trunk/LayoutTests/accessibility/mac/aria-divs-not-ignored-expected.txt 2021-10-15 14:32:36 UTC (rev 284244)
@@ -6,7 +6,7 @@
PASS body.childAtIndex(1).role is 'AXRole: AXGroup'
-PASS body.childAtIndex(1).subrole is 'AXSubrole: AXApplicationLog'
+PASS body.childAtIndex(1).subrole is 'AXSubrole: AXEmptyGroup'
PASS successfullyParsed is true
TEST COMPLETE
Modified: trunk/LayoutTests/accessibility/mac/aria-divs-not-ignored.html (284243 => 284244)
--- trunk/LayoutTests/accessibility/mac/aria-divs-not-ignored.html 2021-10-15 14:01:05 UTC (rev 284243)
+++ trunk/LayoutTests/accessibility/mac/aria-divs-not-ignored.html 2021-10-15 14:32:36 UTC (rev 284244)
@@ -20,7 +20,9 @@
document.getElementById("body").focus();
var body = accessibilityController.focusedElement;
shouldBe("body.childAtIndex(1).role", "'AXRole: AXGroup'");
- shouldBe("body.childAtIndex(1).subrole", "'AXSubrole: AXApplicationLog'");
+ // Because this div has nothing in it, we expect the AXEmptyGroup subrole. A role="log" element with
+ // content would have a different subrole (i.e. AXApplicationLog).
+ shouldBe("body.childAtIndex(1).subrole", "'AXSubrole: AXEmptyGroup'");
}
</script>
Added: trunk/LayoutTests/accessibility/mac/empty-group-computation-expected.txt (0 => 284244)
--- trunk/LayoutTests/accessibility/mac/empty-group-computation-expected.txt (rev 0)
+++ trunk/LayoutTests/accessibility/mac/empty-group-computation-expected.txt 2021-10-15 14:32:36 UTC (rev 284244)
@@ -0,0 +1,32 @@
+This test ensures WebKit properly reports groups as empty (or not empty).
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+Testing element with ID: empty-group-with-title
+PASS group.subrole is 'AXSubrole: AXEmptyGroup'
+Testing element with ID: empty-div-with-label
+PASS group.subrole is 'AXSubrole: AXEmptyGroup'
+Testing element with ID: empty-group-with-title-and-br
+PASS group.subrole is 'AXSubrole: AXEmptyGroup'
+Testing element with ID: group-with-direct-text-descendant
+PASS group.subrole is 'AXSubrole: AXApplicationGroup'
+Testing element with ID: group-with-non-empty-div
+PASS group.subrole is 'AXSubrole: AXApplicationGroup'
+Testing element with ID: group-with-heading
+PASS group.subrole is 'AXSubrole: AXApplicationGroup'
+Testing element with ID: group-with-contenteditable
+PASS group.subrole is 'AXSubrole: AXApplicationGroup'
+Testing element with ID: group-with-empty-table
+PASS group.subrole is 'AXSubrole: AXApplicationGroup'
+Testing element with ID: group-with-nested-content
+PASS group.subrole is 'AXSubrole: AXApplicationGroup'
+Testing element with ID: group-with-image
+PASS group.subrole is 'AXSubrole: AXApplicationGroup'
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
+
+
+
Added: trunk/LayoutTests/accessibility/mac/empty-group-computation.html (0 => 284244)
--- trunk/LayoutTests/accessibility/mac/empty-group-computation.html (rev 0)
+++ trunk/LayoutTests/accessibility/mac/empty-group-computation.html 2021-10-15 14:32:36 UTC (rev 284244)
@@ -0,0 +1,92 @@
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<html>
+<head>
+<script src=""
+<script src=""
+</head>
+<body>
+
+<div id="content">
+ <div id="empty-group-with-title" role="group" title="Group title"></div>
+
+ <div id="empty-div-with-label" aria-label="Div label"></div>
+
+ <div id="empty-group-with-title-and-br" role="group" title="Group title">
+ <!-- BR tags are ignored, so include one here to ensure we skip ignored content. -->
+ <br />
+ </div>
+
+ <div id="group-with-direct-text-descendant" role="group" aria-label="Group label">
+ Child text
+ </div>
+
+ <div id="group-with-non-empty-div" role="group" title="Group title">
+ <div>
+ Group title
+ </div>
+ </div>
+
+ <div id="group-with-heading" role="group" aria-label="Group label">
+ <h1>
+ <div>Hello world</div>
+ </h1>
+ </div>
+
+ <div id="group-with-contenteditable" role="group" aria-label="Group label">
+ <div contenteditable="true"></div>
+ </div>
+
+ <div id="group-with-empty-table" role="group" aria-label="Group label">
+ <table>
+ <thead>
+ </thead>
+ <tbody>
+ </tbody>
+ </table>
+ </div>
+
+ <div id="group-with-nested-content" role="group" aria-label="Group label">
+ <!-- BR tags are ignored, so include one here to ensure we skip ignored content. -->
+ <br />
+ <div>
+ <div>
+ Text
+ </div>
+ </div>
+ </div>
+
+ <div id="group-with-image" role="group" aria-label="Group label">
+ <img src="" _onload_="runTest()">
+ </div>
+</div>
+
+<script>
+ description("This test ensures WebKit properly reports groups as empty (or not empty).")
+
+ var group;
+ const runTest = () => {
+ if (window.accessibilityController) {
+ const groupShouldBeEmpty = (id, shouldBeEmpty) => {
+ group = accessibilityController.accessibleElementById(id);
+ debug(`Testing element with ID: ${id}`);
+ shouldBe("group.subrole", shouldBeEmpty ? "'AXSubrole: AXEmptyGroup'" : "'AXSubrole: AXApplicationGroup'");
+ };
+
+ groupShouldBeEmpty("empty-group-with-title", true);
+ groupShouldBeEmpty("empty-div-with-label", true);
+ groupShouldBeEmpty("empty-group-with-title-and-br", true);
+ groupShouldBeEmpty("group-with-direct-text-descendant", false);
+ groupShouldBeEmpty("group-with-non-empty-div", false);
+ groupShouldBeEmpty("group-with-heading", false);
+ groupShouldBeEmpty("group-with-contenteditable", false);
+ groupShouldBeEmpty("group-with-empty-table", false);
+ groupShouldBeEmpty("group-with-nested-content", false);
+ groupShouldBeEmpty("group-with-image", false);
+
+ document.getElementById("content").style.visibility = "hidden";
+ }
+ }
+</script>
+</body>
+</html>
+
Added: trunk/LayoutTests/platform/mac/accessibility/lists-expected.txt (0 => 284244)
--- trunk/LayoutTests/platform/mac/accessibility/lists-expected.txt (rev 0)
+++ trunk/LayoutTests/platform/mac/accessibility/lists-expected.txt 2021-10-15 14:32:36 UTC (rev 284244)
@@ -0,0 +1,429 @@
+test 1
+test 2
+test 1
+test 2
+term 1
+meaning 2
+term b
+meaning 1
+meaning 2
+
+
+
+
+AXRole: AXList
+AXSubrole: AXContentList
+AXRoleDescription: content list
+AXChildren: <array of size 2>
+AXHelp:
+AXParent: <AXList>
+AXSize: NSSize: {784, 36}
+AXTitle:
+AXDescription:
+AXValue:
+AXFocused: 0
+AXEnabled: 1
+AXWindow: <AXList>
+AXSelectedTextMarkerRange: (null)
+AXStartTextMarker: <AXList>
+AXEndTextMarker: <AXList>
+AXVisited: 0
+AXLinkedUIElements: <array of size 0>
+AXSelected: 0
+AXBlockQuoteLevel: 0
+AXTopLevelUIElement: <AXList>
+AXLanguage:
+AXDOMIdentifier:
+AXDOMClassList: <array of size 0>
+AXFocusableAncestor: <AXList>
+AXEditableAncestor: (null)
+AXHighestEditableAncestor: (null)
+AXSelectedChildren: <array of size 0>
+AXVisibleChildren: <array of size 2>
+AXOrientation: AXVerticalOrientation
+AXTitleUIElement: (null)
+AXElementBusy: 0
+
+------------
+AXRole: AXList
+AXSubrole: AXContentList
+AXRoleDescription: content list
+AXChildren: <array of size 2>
+AXHelp:
+AXParent: <AXList>
+AXSize: NSSize: {784, 36}
+AXTitle:
+AXDescription:
+AXValue:
+AXFocused: 0
+AXEnabled: 1
+AXWindow: <AXList>
+AXSelectedTextMarkerRange: (null)
+AXStartTextMarker: <AXList>
+AXEndTextMarker: <AXList>
+AXVisited: 0
+AXLinkedUIElements: <array of size 0>
+AXSelected: 0
+AXBlockQuoteLevel: 0
+AXTopLevelUIElement: <AXList>
+AXLanguage:
+AXDOMIdentifier:
+AXDOMClassList: <array of size 0>
+AXFocusableAncestor: <AXList>
+AXEditableAncestor: (null)
+AXHighestEditableAncestor: (null)
+AXSelectedChildren: <array of size 0>
+AXVisibleChildren: <array of size 2>
+AXOrientation: AXVerticalOrientation
+AXTitleUIElement: (null)
+AXElementBusy: 0
+
+------------
+AXRole: AXList
+AXSubrole: AXDescriptionList
+AXRoleDescription: description list
+AXChildren: <array of size 5>
+AXHelp:
+AXParent: <AXList>
+AXSize: NSSize: {784, 90}
+AXTitle:
+AXDescription:
+AXValue:
+AXFocused: 0
+AXEnabled: 1
+AXWindow: <AXList>
+AXSelectedTextMarkerRange: (null)
+AXStartTextMarker: <AXList>
+AXEndTextMarker: <AXList>
+AXVisited: 0
+AXLinkedUIElements: <array of size 0>
+AXSelected: 0
+AXBlockQuoteLevel: 0
+AXTopLevelUIElement: <AXList>
+AXLanguage:
+AXDOMIdentifier:
+AXDOMClassList: <array of size 0>
+AXFocusableAncestor: <AXList>
+AXEditableAncestor: (null)
+AXHighestEditableAncestor: (null)
+AXSelectedChildren: (null)
+AXVisibleChildren: <array of size 5>
+AXOrientation: AXVerticalOrientation
+AXTitleUIElement: (null)
+AXElementBusy: 0
+
+------------
+AXRole: AXGroup
+AXSubrole: AXEmptyGroup
+AXRoleDescription: group
+AXChildren: <array of size 0>
+AXHelp:
+AXParent: <AXGroup>
+AXSize: NSSize: {784, 72}
+AXTitle:
+AXDescription:
+AXValue:
+AXFocused: 0
+AXEnabled: 1
+AXWindow: <AXGroup>
+AXSelectedTextMarkerRange: (null)
+AXStartTextMarker: <AXGroup>
+AXEndTextMarker: <AXGroup>
+AXVisited: 0
+AXLinkedUIElements: <array of size 0>
+AXSelected: 0
+AXBlockQuoteLevel: 0
+AXTopLevelUIElement: <AXGroup>
+AXLanguage:
+AXDOMIdentifier:
+AXDOMClassList: <array of size 0>
+AXFocusableAncestor: <AXGroup>
+AXEditableAncestor: (null)
+AXHighestEditableAncestor: (null)
+AXTitleUIElement: (null)
+AXElementBusy: 0
+
+------------
+
+
+AXRole: AXGroup
+AXSubrole: (null)
+AXRoleDescription: group
+AXChildren: <array of size 2>
+AXHelp:
+AXParent: <AXGroup>
+AXSize: NSSize: {729, 18}
+AXTitle:
+AXDescription:
+AXValue:
+AXFocused: 0
+AXEnabled: 1
+AXWindow: <AXGroup>
+AXSelectedTextMarkerRange: (null)
+AXStartTextMarker: <AXGroup>
+AXEndTextMarker: <AXGroup>
+AXVisited: 0
+AXLinkedUIElements: <array of size 0>
+AXSelected: 0
+AXBlockQuoteLevel: 0
+AXTopLevelUIElement: <AXGroup>
+AXLanguage:
+AXDOMIdentifier:
+AXDOMClassList: <array of size 0>
+AXFocusableAncestor: <AXGroup>
+AXEditableAncestor: (null)
+AXHighestEditableAncestor: (null)
+AXTitleUIElement: (null)
+AXElementBusy: 0
+
+------------
+AXRole: AXGroup
+AXSubrole: (null)
+AXRoleDescription: group
+AXChildren: <array of size 2>
+AXHelp:
+AXParent: <AXGroup>
+AXSize: NSSize: {729, 18}
+AXTitle:
+AXDescription:
+AXValue:
+AXFocused: 0
+AXEnabled: 1
+AXWindow: <AXGroup>
+AXSelectedTextMarkerRange: (null)
+AXStartTextMarker: <AXGroup>
+AXEndTextMarker: <AXGroup>
+AXVisited: 0
+AXLinkedUIElements: <array of size 0>
+AXSelected: 0
+AXBlockQuoteLevel: 0
+AXTopLevelUIElement: <AXGroup>
+AXLanguage:
+AXDOMIdentifier:
+AXDOMClassList: <array of size 0>
+AXFocusableAncestor: <AXGroup>
+AXEditableAncestor: (null)
+AXHighestEditableAncestor: (null)
+AXTitleUIElement: (null)
+AXElementBusy: 0
+
+------------
+
+
+AXRole: AXGroup
+AXSubrole: (null)
+AXRoleDescription: group
+AXChildren: <array of size 2>
+AXHelp:
+AXParent: <AXGroup>
+AXSize: NSSize: {729, 18}
+AXTitle:
+AXDescription:
+AXValue:
+AXFocused: 0
+AXEnabled: 1
+AXWindow: <AXGroup>
+AXSelectedTextMarkerRange: (null)
+AXStartTextMarker: <AXGroup>
+AXEndTextMarker: <AXGroup>
+AXVisited: 0
+AXLinkedUIElements: <array of size 0>
+AXSelected: 0
+AXBlockQuoteLevel: 0
+AXTopLevelUIElement: <AXGroup>
+AXLanguage:
+AXDOMIdentifier:
+AXDOMClassList: <array of size 0>
+AXFocusableAncestor: <AXGroup>
+AXEditableAncestor: (null)
+AXHighestEditableAncestor: (null)
+AXTitleUIElement: (null)
+AXElementBusy: 0
+
+------------
+AXRole: AXGroup
+AXSubrole: (null)
+AXRoleDescription: group
+AXChildren: <array of size 2>
+AXHelp:
+AXParent: <AXGroup>
+AXSize: NSSize: {729, 18}
+AXTitle:
+AXDescription:
+AXValue:
+AXFocused: 0
+AXEnabled: 1
+AXWindow: <AXGroup>
+AXSelectedTextMarkerRange: (null)
+AXStartTextMarker: <AXGroup>
+AXEndTextMarker: <AXGroup>
+AXVisited: 0
+AXLinkedUIElements: <array of size 0>
+AXSelected: 0
+AXBlockQuoteLevel: 0
+AXTopLevelUIElement: <AXGroup>
+AXLanguage:
+AXDOMIdentifier:
+AXDOMClassList: <array of size 0>
+AXFocusableAncestor: <AXGroup>
+AXEditableAncestor: (null)
+AXHighestEditableAncestor: (null)
+AXTitleUIElement: (null)
+AXElementBusy: 0
+
+------------
+
+
+AXRole: AXGroup
+AXSubrole: AXTerm
+AXRoleDescription: term
+AXChildren: <array of size 1>
+AXHelp:
+AXParent: <AXGroup>
+AXSize: NSSize: {769, 18}
+AXTitle:
+AXDescription:
+AXValue:
+AXFocused: 0
+AXEnabled: 1
+AXWindow: <AXGroup>
+AXSelectedTextMarkerRange: (null)
+AXStartTextMarker: <AXGroup>
+AXEndTextMarker: <AXGroup>
+AXVisited: 0
+AXLinkedUIElements: <array of size 0>
+AXSelected: 0
+AXBlockQuoteLevel: 0
+AXTopLevelUIElement: <AXGroup>
+AXLanguage:
+AXDOMIdentifier:
+AXDOMClassList: <array of size 0>
+AXFocusableAncestor: <AXGroup>
+AXEditableAncestor: (null)
+AXHighestEditableAncestor: (null)
+AXElementBusy: 0
+
+------------
+AXRole: AXGroup
+AXSubrole: AXDescription
+AXRoleDescription: description
+AXChildren: <array of size 1>
+AXHelp:
+AXParent: <AXGroup>
+AXSize: NSSize: {729, 18}
+AXTitle:
+AXDescription:
+AXValue:
+AXFocused: 0
+AXEnabled: 1
+AXWindow: <AXGroup>
+AXSelectedTextMarkerRange: (null)
+AXStartTextMarker: <AXGroup>
+AXEndTextMarker: <AXGroup>
+AXVisited: 0
+AXLinkedUIElements: <array of size 0>
+AXSelected: 0
+AXBlockQuoteLevel: 0
+AXTopLevelUIElement: <AXGroup>
+AXLanguage:
+AXDOMIdentifier:
+AXDOMClassList: <array of size 0>
+AXFocusableAncestor: <AXGroup>
+AXEditableAncestor: (null)
+AXHighestEditableAncestor: (null)
+AXElementBusy: 0
+
+------------
+AXRole: AXGroup
+AXSubrole: AXTerm
+AXRoleDescription: term
+AXChildren: <array of size 1>
+AXHelp:
+AXParent: <AXGroup>
+AXSize: NSSize: {769, 18}
+AXTitle:
+AXDescription:
+AXValue:
+AXFocused: 0
+AXEnabled: 1
+AXWindow: <AXGroup>
+AXSelectedTextMarkerRange: (null)
+AXStartTextMarker: <AXGroup>
+AXEndTextMarker: <AXGroup>
+AXVisited: 0
+AXLinkedUIElements: <array of size 0>
+AXSelected: 0
+AXBlockQuoteLevel: 0
+AXTopLevelUIElement: <AXGroup>
+AXLanguage:
+AXDOMIdentifier:
+AXDOMClassList: <array of size 0>
+AXFocusableAncestor: <AXGroup>
+AXEditableAncestor: (null)
+AXHighestEditableAncestor: (null)
+AXElementBusy: 0
+
+------------
+AXRole: AXGroup
+AXSubrole: AXDescription
+AXRoleDescription: description
+AXChildren: <array of size 1>
+AXHelp:
+AXParent: <AXGroup>
+AXSize: NSSize: {729, 18}
+AXTitle:
+AXDescription:
+AXValue:
+AXFocused: 0
+AXEnabled: 1
+AXWindow: <AXGroup>
+AXSelectedTextMarkerRange: (null)
+AXStartTextMarker: <AXGroup>
+AXEndTextMarker: <AXGroup>
+AXVisited: 0
+AXLinkedUIElements: <array of size 0>
+AXSelected: 0
+AXBlockQuoteLevel: 0
+AXTopLevelUIElement: <AXGroup>
+AXLanguage:
+AXDOMIdentifier:
+AXDOMClassList: <array of size 0>
+AXFocusableAncestor: <AXGroup>
+AXEditableAncestor: (null)
+AXHighestEditableAncestor: (null)
+AXElementBusy: 0
+
+------------
+AXRole: AXGroup
+AXSubrole: AXDescription
+AXRoleDescription: description
+AXChildren: <array of size 1>
+AXHelp:
+AXParent: <AXGroup>
+AXSize: NSSize: {729, 18}
+AXTitle:
+AXDescription:
+AXValue:
+AXFocused: 0
+AXEnabled: 1
+AXWindow: <AXGroup>
+AXSelectedTextMarkerRange: (null)
+AXStartTextMarker: <AXGroup>
+AXEndTextMarker: <AXGroup>
+AXVisited: 0
+AXLinkedUIElements: <array of size 0>
+AXSelected: 0
+AXBlockQuoteLevel: 0
+AXTopLevelUIElement: <AXGroup>
+AXLanguage:
+AXDOMIdentifier:
+AXDOMClassList: <array of size 0>
+AXFocusableAncestor: <AXGroup>
+AXEditableAncestor: (null)
+AXHighestEditableAncestor: (null)
+AXElementBusy: 0
+
+------------
+
+
+
Added: trunk/LayoutTests/platform/mac/accessibility/plugin-expected.txt (0 => 284244)
--- trunk/LayoutTests/platform/mac/accessibility/plugin-expected.txt (rev 0)
+++ trunk/LayoutTests/platform/mac/accessibility/plugin-expected.txt 2021-10-15 14:32:36 UTC (rev 284244)
@@ -0,0 +1,35 @@
+
+AXRole: AXGroup
+AXSubrole: AXEmptyGroup
+AXRoleDescription: group
+AXChildren: <array of size 0>
+AXHelp:
+AXParent: <AXGroup>
+AXSize: NSSize: {784, 150}
+AXTitle:
+AXDescription:
+AXValue:
+AXFocused: 0
+AXEnabled: 1
+AXWindow: <AXGroup>
+AXSelectedTextMarkerRange: (null)
+AXStartTextMarker: <AXGroup>
+AXEndTextMarker: <AXGroup>
+AXVisited: 0
+AXLinkedUIElements: <array of size 0>
+AXSelected: 0
+AXBlockQuoteLevel: 0
+AXTopLevelUIElement: <AXGroup>
+AXLanguage:
+AXDOMIdentifier:
+AXDOMClassList: <array of size 0>
+AXFocusableAncestor: <AXGroup>
+AXEditableAncestor: (null)
+AXHighestEditableAncestor: (null)
+AXTitleUIElement: (null)
+AXElementBusy: 0
+
+------------
+
+
+
Modified: trunk/LayoutTests/platform/mac/accessibility/svg-element-with-aria-role-expected.txt (284243 => 284244)
--- trunk/LayoutTests/platform/mac/accessibility/svg-element-with-aria-role-expected.txt 2021-10-15 14:01:05 UTC (rev 284243)
+++ trunk/LayoutTests/platform/mac/accessibility/svg-element-with-aria-role-expected.txt 2021-10-15 14:32:36 UTC (rev 284244)
@@ -5,7 +5,7 @@
test1: AXRole: AXGroup AXSubrole: AXDocument
-test2: AXRole: AXGroup AXSubrole:
+test2: AXRole: AXGroup AXSubrole: AXEmptyGroup
test3: AXRole: AXButton AXSubrole:
PASS successfullyParsed is true
Modified: trunk/Source/WebCore/ChangeLog (284243 => 284244)
--- trunk/Source/WebCore/ChangeLog 2021-10-15 14:01:05 UTC (rev 284243)
+++ trunk/Source/WebCore/ChangeLog 2021-10-15 14:32:36 UTC (rev 284244)
@@ -1,3 +1,19 @@
+2021-10-15 Tyler Wilcock <[email protected]>
+
+ AX: Return AXEmptyGroup subrole for groups with no accessible content
+ https://bugs.webkit.org/show_bug.cgi?id=231528
+
+ Reviewed by Andres Gonzalez.
+
+ Return a subrole of "AXEmptyGroup" for groups without any exposed
+ children. WebKit can calculate this more efficiently than AX clients,
+ so it makes more sense to do here.
+
+ Test: accessibility/mac/empty-group-computation.html
+
+ * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
+ (-[WebAccessibilityObjectWrapper subrole]):
+
2021-10-15 Alan Bujtas <[email protected]>
[LFC][IFC] Do not break the word-wrap: break-word content on inline box boundary
Modified: trunk/Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm (284243 => 284244)
--- trunk/Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm 2021-10-15 14:01:05 UTC (rev 284243)
+++ trunk/Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm 2021-10-15 14:32:36 UTC (rev 284244)
@@ -1834,6 +1834,10 @@
if (backingObject->isMeter())
return @"AXMeter";
+ // Treat any group without exposed children as empty.
+ if ([[self role] isEqual:NSAccessibilityGroupRole] && !backingObject->children().size())
+ return @"AXEmptyGroup";
+
AccessibilityRole role = backingObject->roleValue();
if (role == AccessibilityRole::HorizontalRule)
return NSAccessibilityContentSeparatorSubrole;