New issue
Advanced search Search tips

Issue 717846 link

Starred by 1 user

Issue metadata

Status: Started
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Android , Windows , Mac
Pri: 3
Type: Bug
Team-Accessibility

Blocking:
issue 679247



Sign in to add a comment

A11y: Unify supported action logic for a11y elements

Project Member Reported by patricia...@chromium.org, May 3 2017

Issue description

A11y elements should have a way to indicate what actions they support without requiring a11y clients to actually try invoking the action*. An action listed in AXAction can be performed on the element via AXPlatformNodeDelegate::AccessibilityPerformAction(), but there is no way to tell if doing this will actually change anything (or just be ignored by the control it's performed on). We currently do this by applying blanket assumptions to an a11y element's role; e.g. we assume that AX_ROLE_BUTTONs are clickable (see ui/accessibility/ax_role_properties.cc). However, we would like to support more use cases, such as Chrome's back button supporting left and right click actions (but not the refresh button, which only supports left click), or a numerical editable combo box that also provides "increment" and "decrement" actions.

* There are two exceptions to this:
   - The AXIntAttribute AX_ATTR_ACTION. If this is set, this indicates that the a11y element supports the AX_ACTION_DO_DEFAULT action (which is a click). All its possible values (listed in the AXSupportedAction enum) are just string indicators to describe what happens to the control when it's clicked, e.g. an unchecked checkbox gets "checked" when it's clicked.
   - The AXBoolAttribute "can_set_value", which indicates whether AX_ACTION_SET_VALUE is supported.

It should also be noted that there is also an enum called AXSupportedAction, which is (as mentioned in the first exception) used to describe what the result of performing the default action on a control will be. This should be renamed when this is fixed, since it might be confusing.
 
Project Member

Comment 1 by bugdroid1@chromium.org, May 9 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/34b559296ecf1005c41ea8278327ef5880553de0

commit 34b559296ecf1005c41ea8278327ef5880553de0
Author: patricialor <patricialor@chromium.org>
Date: Tue May 09 06:09:36 2017

A11y: Add/refactor methods for manipulating bitfields on AXNodeData.

In preparation for allowing a11y elements to indicate they support a
user-executable action (e.g. checking a checkbox), this change does two things:
 - Rename AXNodeData::AddStateFlag() / AXNodeData::HasStateFlag() to
   AXNodeData::AddState() for a consistent naming scheme.
 - Add a new method AXNodeData::ClearBitfields(), which will clear the bits set
   on AXNodeData::state. New bitfields added onto AXNodeData can also be cleared
   here.
 - Deletes AXNodeData::IsFlagSet() and replaces this with HasState() above.

BUG=717846

Review-Url: https://codereview.chromium.org/2860883003
Cr-Commit-Position: refs/heads/master@{#470245}

[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ash/system/audio/volume_view.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ash/system/ime_menu/ime_menu_tray_unittest.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/chrome/browser/chromeos/arc/accessibility/ax_tree_source_arc.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/chrome/browser/ui/aura/accessibility/ax_root_obj_wrapper.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/chrome/browser/ui/views/download/download_item_view.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/chrome/browser/ui/views/omnibox/omnibox_view_views.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/chrome/browser/ui/views/page_info/non_accessible_image_view.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/chrome/browser/ui/views/tabs/tab.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/chrome/browser/ui/views/toolbar/toolbar_button.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/components/pdf/renderer/pdf_accessibility_tree.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/content/browser/accessibility/browser_accessibility.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/content/browser/accessibility/browser_accessibility_manager_android.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/content/browser/accessibility/browser_accessibility_manager_auralinux.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/content/browser/accessibility/browser_accessibility_manager_mac.mm
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/content/browser/accessibility/browser_accessibility_manager_unittest.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/content/browser/accessibility/browser_accessibility_manager_win.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/content/browser/accessibility/browser_accessibility_win_unittest.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/content/browser/accessibility/one_shot_accessibility_tree_search_unittest.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/content/renderer/accessibility/blink_ax_tree_source.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/accessibility/ax_node_data.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/accessibility/ax_node_data.h
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/accessibility/ax_node_position_unittest.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/accessibility/ax_tree.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/accessibility/ax_tree_fuzzer.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/accessibility/ax_tree_unittest.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/accessibility/platform/ax_platform_node_auralinux.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/accessibility/platform/ax_platform_node_mac.mm
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/accessibility/tree_generator.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/accessibility/ax_view_obj_wrapper.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/accessibility/ax_window_obj_wrapper.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/accessibility/native_view_accessibility_base.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/accessibility/native_view_accessibility_unittest.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/button/button.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/button/custom_button.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/button/image_button.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/button/menu_button.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/label.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/label_unittest.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/menu/menu_item_view.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/menu/submenu_view.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/progress_bar.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/progress_bar_unittest.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/tabbed_pane/tabbed_pane.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/tabbed_pane/tabbed_pane_unittest.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/table/table_view.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/textfield/textfield.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/textfield/textfield_unittest.cc
[modify] https://crrev.com/34b559296ecf1005c41ea8278327ef5880553de0/ui/views/controls/tree/tree_view.cc

Project Member

Comment 2 by bugdroid1@chromium.org, May 18 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/fee367ad5f048733aba40a3a7b64ddb7967355dc

commit fee367ad5f048733aba40a3a7b64ddb7967355dc
Author: patricialor <patricialor@chromium.org>
Date: Thu May 18 06:52:00 2017

A11y: Rename AXSupportedAction to AXDefaultActionVerb.

The AXSupportedAction enum is used to identify the appropriate string to use
when a11y clients need to know the action that will occur on an a11y element
when performing the default action, which is a click. Avoid any confusion with
the AXActions an a11y element supports by renaming it.

BUG=717846

Review-Url: https://codereview.chromium.org/2863703003
Cr-Commit-Position: refs/heads/master@{#472715}

[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/chrome/browser/ui/views/toolbar/toolbar_button.cc
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/content/browser/accessibility/browser_accessibility_android.cc
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/content/browser/accessibility/browser_accessibility_auralinux.cc
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/content/browser/accessibility/browser_accessibility_com_win.cc
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/content/renderer/accessibility/blink_ax_enum_conversion.cc
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/content/renderer/accessibility/blink_ax_enum_conversion.h
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/content/renderer/accessibility/blink_ax_tree_source.cc
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/content/test/data/accessibility/html/action-verbs-expected-blink.txt
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/content/test/data/accessibility/html/action-verbs.html
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/third_party/WebKit/Source/modules/accessibility/AXObjectImpl.cpp
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/third_party/WebKit/Source/modules/accessibility/AXObjectImpl.h
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/third_party/WebKit/Source/web/AssertMatchingEnums.cpp
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/third_party/WebKit/Source/web/WebAXObject.cpp
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/third_party/WebKit/public/web/WebAXEnums.h
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/third_party/WebKit/public/web/WebAXObject.h
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/ui/accessibility/ax_enums.idl
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/ui/accessibility/ax_node_data.cc
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/ui/accessibility/ax_text_utils.cc
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/ui/accessibility/ax_text_utils.h
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/ui/accessibility/platform/ax_platform_node_win.cc
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/ui/views/controls/button/checkbox.cc
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/ui/views/controls/button/custom_button.cc
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/ui/views/controls/button/menu_button.cc
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/ui/views/controls/combobox/combobox.cc
[modify] https://crrev.com/fee367ad5f048733aba40a3a7b64ddb7967355dc/ui/views/controls/textfield/textfield.cc

Project Member

Comment 3 by bugdroid1@chromium.org, May 22 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/979beede7c397098ba05931fd1f29792a95472eb

commit 979beede7c397098ba05931fd1f29792a95472eb
Author: patricialor <patricialor@chromium.org>
Date: Mon May 22 06:24:22 2017

Views a11y: Add AXNodeData.actions bitfield to indicate supported actions by UI.

AXActions are used to perform actions on an a11y element, such as changing the
value of a textfield, focus/blur an element, etc. However, currently there is no
way to indicate that an element actually supports that particular action, e.g.
a numerical combobox that allows text input may support three actions -
'left click' (to focus the text field), 'increment', and 'decrement', but might
not do anything on 'right click' (which would typically show a context menu).

Add a new |actions| bitfield on AXNodeData to allow a11y elements to indicate
which actions they actually support, and remove the |can_set_value| attribute
since we now have a general solution for all AXActions.

BUG=717846

Review-Url: https://codereview.chromium.org/2799413002
Cr-Commit-Position: refs/heads/master@{#473515}

[modify] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/chrome/common/extensions/chrome_extension_messages.h
[modify] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/content/browser/accessibility/accessibility_tree_formatter_blink.cc
[modify] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/content/browser/accessibility/browser_accessibility.cc
[modify] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/content/browser/accessibility/browser_accessibility.h
[modify] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/content/browser/accessibility/browser_accessibility_cocoa.mm
[modify] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/content/browser/accessibility/browser_accessibility_com_win.cc
[modify] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/content/browser/accessibility/cross_platform_accessibility_browsertest.cc
[modify] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/content/browser/accessibility/dump_accessibility_tree_browsertest.cc
[modify] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/content/common/accessibility_messages.h
[modify] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/content/renderer/accessibility/blink_ax_tree_source.cc
[modify] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/content/test/data/accessibility/html/action-verbs-expected-blink.txt
[add] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/content/test/data/accessibility/html/actions-expected-blink.txt
[add] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/content/test/data/accessibility/html/actions.html
[modify] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/ui/accessibility/ax_enums.idl
[modify] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/ui/accessibility/ax_node_data.cc
[modify] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/ui/accessibility/ax_node_data.h
[modify] https://crrev.com/979beede7c397098ba05931fd1f29792a95472eb/ui/accessibility/ax_tree_unittest.cc

Labels: a11y-secondary

Sign in to add a comment