Flutter Engine
Loading...
Searching...
No Matches
ax_action_data.h
Go to the documentation of this file.
1
// Copyright 2016 The Chromium Authors. All rights reserved.
2
// Use of this source code is governed by a BSD-style license that can be
3
// found in the LICENSE file.
4
5
#ifndef UI_ACCESSIBILITY_AX_ACTION_DATA_H_
6
#define UI_ACCESSIBILITY_AX_ACTION_DATA_H_
7
8
#include "
ax_enums.h
"
9
#include "
ax_export.h
"
10
#include "
ax_tree_id.h
"
11
#include "
gfx/geometry/point.h
"
12
#include "
gfx/geometry/rect.h
"
13
14
namespace
ui
{
15
16
// A compact representation of an accessibility action and the arguments
17
// associated with that action.
18
struct
AX_EXPORT
AXActionData
{
19
AXActionData
();
20
AXActionData
(
const
AXActionData
& other);
21
~AXActionData
();
22
23
// This is a simple serializable struct. All member variables should be
24
// public and copyable.
25
26
// See the ax::mojom::Action enums in ax_enums.mojom for explanations of which
27
// parameters apply.
28
29
// The action to take.
30
ax::mojom::Action
action
;
31
32
// The ID of the tree that this action should be performed on.
33
ui::AXTreeID
target_tree_id =
ui::AXTreeIDUnknown
();
34
35
// The source extension id (if any) of this action.
36
std::string
source_extension_id
;
37
38
// The ID of the node that this action should be performed on.
39
int
target_node_id = -1;
40
41
// The request id of this action tracked by the client.
42
int
request_id = -1;
43
44
// Use enums from ax::mojom::ActionFlags
45
int
flags = 0;
46
47
// For an action that creates a selection, the selection anchor and focus
48
// (see ax_tree_data.h for definitions).
49
int
anchor_node_id = -1;
50
int
anchor_offset = -1;
51
52
int
focus_node_id = -1;
53
int
focus_offset = -1;
54
55
// Start index of the text which should be queried for.
56
int32_t start_index = -1;
57
58
// End index of the text which should be queried for.
59
int32_t end_index = -1;
60
61
// For custom action.
62
int
custom_action_id = -1;
63
64
// The target rect for the action.
65
gfx::Rect
target_rect
;
66
67
// The target point for the action.
68
gfx::Point
target_point
;
69
70
// The new value for a node, for the SET_VALUE action. UTF-8 encoded.
71
std::string
value
;
72
73
// The event to fire in response to a HIT_TEST action.
74
ax::mojom::Event
hit_test_event_to_fire
;
75
76
// The scroll alignment to use for a SCROLL_TO_MAKE_VISIBLE action. The
77
// scroll alignment controls where a node is scrolled within the viewport.
78
ax::mojom::ScrollAlignment
horizontal_scroll_alignment
;
79
ax::mojom::ScrollAlignment
vertical_scroll_alignment
;
80
81
// The behavior to use for a SCROLL_TO_MAKE_VISIBLE. This controls whether or
82
// not the viewport is scrolled when the node is already visible.
83
ax::mojom::ScrollBehavior
scroll_behavior
;
84
};
85
86
}
// namespace ui
87
88
#endif
// UI_ACCESSIBILITY_AX_ACTION_DATA_H_
ax_enums.h
ax_export.h
AX_EXPORT
#define AX_EXPORT
Definition
ax_export.h:29
ax_tree_id.h
gfx::Point
Definition
point.h:27
gfx::Rect
Definition
rect.h:36
ui::AXTreeID
Definition
ax_tree_id.h:18
ax::mojom::ScrollBehavior
ScrollBehavior
Definition
ax_enums.h:475
ax::mojom::ScrollAlignment
ScrollAlignment
Definition
ax_enums.h:460
ax::mojom::Action
Action
Definition
ax_enums.h:347
ax::mojom::Event
Event
Definition
ax_enums.h:31
ui
Definition
window_binding_handler.h:19
ui::AXTreeIDUnknown
const AXTreeID & AXTreeIDUnknown()
Definition
ax_tree_id.cc:103
ui::AXActionData
Definition
ax_action_data.h:18
ui::AXActionData::scroll_behavior
ax::mojom::ScrollBehavior scroll_behavior
Definition
ax_action_data.h:83
ui::AXActionData::value
std::string value
Definition
ax_action_data.h:71
ui::AXActionData::vertical_scroll_alignment
ax::mojom::ScrollAlignment vertical_scroll_alignment
Definition
ax_action_data.h:79
ui::AXActionData::source_extension_id
std::string source_extension_id
Definition
ax_action_data.h:36
ui::AXActionData::hit_test_event_to_fire
ax::mojom::Event hit_test_event_to_fire
Definition
ax_action_data.h:74
ui::AXActionData::target_rect
gfx::Rect target_rect
Definition
ax_action_data.h:65
ui::AXActionData::AXActionData
AXActionData(const AXActionData &other)
ui::AXActionData::action
ax::mojom::Action action
Definition
ax_action_data.h:30
ui::AXActionData::~AXActionData
~AXActionData()
ui::AXActionData::target_point
gfx::Point target_point
Definition
ax_action_data.h:68
ui::AXActionData::horizontal_scroll_alignment
ax::mojom::ScrollAlignment horizontal_scroll_alignment
Definition
ax_action_data.h:78
point.h
rect.h
third_party
accessibility
ax
ax_action_data.h
Generated on Thu Nov 6 2025 16:11:29 for Flutter Engine by
1.9.8