OLD | NEW |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef UI_ACCESSIBILITY_AX_ROLE_PROPERTIES_H_ | 5 #ifndef UI_ACCESSIBILITY_AX_ROLE_PROPERTIES_H_ |
6 #define UI_ACCESSIBILITY_AX_ROLE_PROPERTIES_H_ | 6 #define UI_ACCESSIBILITY_AX_ROLE_PROPERTIES_H_ |
7 | 7 |
8 #include "ui/accessibility/ax_enums.h" | 8 #include "ui/accessibility/ax_enums.h" |
9 #include "ui/accessibility/ax_export.h" | 9 #include "ui/accessibility/ax_export.h" |
10 | 10 |
11 namespace ui { | 11 namespace ui { |
12 | 12 |
13 // Checks if the given role should belong to a control that can respond to | 13 // Checks if the given role should belong to a control that can respond to |
14 // clicks. | 14 // clicks. |
15 AX_EXPORT bool IsRoleClickable(AXRole role); | 15 AX_EXPORT bool IsRoleClickable(AXRole role); |
16 | 16 |
17 // Returns true if this node is a cell or a table header. | 17 // Returns true if this node is a cell or a table header. |
18 AX_EXPORT bool IsCellOrTableHeaderRole(AXRole role); | 18 AX_EXPORT bool IsCellOrTableHeaderRole(AXRole role); |
19 | 19 |
20 // Returns true if this node is a table, a grid or a treegrid. | 20 // Returns true if this node is a table, a grid or a treegrid. |
21 AX_EXPORT bool IsTableLikeRole(AXRole role); | 21 AX_EXPORT bool IsTableLikeRole(AXRole role); |
22 | 22 |
23 // Returns true if this node is a container with selectable children. | 23 // Returns true if this node is a container with selectable children. |
24 AX_EXPORT bool IsContainerWithSelectableChildrenRole(ui::AXRole role); | 24 AX_EXPORT bool IsContainerWithSelectableChildrenRole(ui::AXRole role); |
25 | 25 |
26 // Returns true if this node is a row container. | 26 // Returns true if this node is a row container. |
27 AX_EXPORT bool IsRowContainer(ui::AXRole role); | 27 AX_EXPORT bool IsRowContainer(ui::AXRole role); |
28 | 28 |
| 29 // Returns true if this node is a control. |
| 30 AX_EXPORT bool IsControl(ui::AXRole role); |
| 31 |
| 32 // Returns true if this node is a menu or related role. |
| 33 AX_EXPORT bool IsMenuRelated(ui::AXRole role); |
| 34 |
29 } // namespace ui | 35 } // namespace ui |
30 | 36 |
31 #endif // UI_ACCESSIBILITY_AX_ROLE_PROPERTIES_H_ | 37 #endif // UI_ACCESSIBILITY_AX_ROLE_PROPERTIES_H_ |
OLD | NEW |