-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
AX: Make AccessibilityListBoxOption derive from AccessibilityNodeObject.
https://bugs.webkit.org/show_bug.cgi?id=269427 <rdar://problem/122987407> Reviewed by Tyler Wilcock. This allows to use downcast in the AccessibilityNodeObject implementation when the object is actually a ListBoxOption. This provieds several advantages in the implementation of methods such as AccessibilityNodeObject::stringValue() and text(). This fixes an issue of VoiceOver not speaking some option elements in <select>. In addition, there is no downside to doing this since previously the ListBoxOption was keeping a reference to an HTMLElement that was either downcast to an HTMLOptionElement or HTmLOptGroupElement. Now we do the same downcasting of a Node object. Some code cleanup included. * LayoutTests/inspector/dom/getAccessibilityPropertiesForNode-expected.txt: * LayoutTests/platform/gtk/inspector/dom/getAccessibilityPropertiesForNode-expected.txt: * Source/WebCore/accessibility/AccessibilityListBoxOption.cpp: (WebCore::AccessibilityListBoxOption::AccessibilityListBoxOption): (WebCore::AccessibilityListBoxOption::isEnabled const): (WebCore::AccessibilityListBoxOption::isSelected const): (WebCore::AccessibilityListBoxOption::elementRect const): (WebCore::AccessibilityListBoxOption::computeAccessibilityIsIgnored const): (WebCore::AccessibilityListBoxOption::canSetSelectedAttribute const): (WebCore::AccessibilityListBoxOption::stringValue const): (WebCore::AccessibilityListBoxOption::actionElement const): (WebCore::AccessibilityListBoxOption::node const): (WebCore::AccessibilityListBoxOption::parentObject const): (WebCore::AccessibilityListBoxOption::listBoxOptionParentNode const): (WebCore::AccessibilityListBoxOption::listBoxOptionIndex const): * Source/WebCore/accessibility/AccessibilityListBoxOption.h: * Source/WebCore/accessibility/AccessibilityNodeObject.h: Canonical link: https://commits.webkit.org/274795@main
- Loading branch information
1 parent
2c6e63f
commit 549911e
Showing
5 changed files
with
67 additions
and
75 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters