OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_VIEWS_ACCESSIBILITY_AX_AURA_OBJ_WRAPPER_H_ | 5 #ifndef UI_VIEWS_ACCESSIBILITY_AX_AURA_OBJ_WRAPPER_H_ |
6 #define UI_VIEWS_ACCESSIBILITY_AX_AURA_OBJ_WRAPPER_H_ | 6 #define UI_VIEWS_ACCESSIBILITY_AX_AURA_OBJ_WRAPPER_H_ |
7 | 7 |
| 8 #include <stdint.h> |
| 9 |
8 #include <vector> | 10 #include <vector> |
9 | 11 |
10 #include "base/basictypes.h" | |
11 #include "base/compiler_specific.h" | 12 #include "base/compiler_specific.h" |
12 #include "base/macros.h" | 13 #include "base/macros.h" |
13 #include "ui/gfx/geometry/point.h" | 14 #include "ui/gfx/geometry/point.h" |
14 #include "ui/views/views_export.h" | 15 #include "ui/views/views_export.h" |
15 | 16 |
16 namespace ui { | 17 namespace ui { |
17 struct AXNodeData; | 18 struct AXNodeData; |
18 } // namespace ui | 19 } // namespace ui |
19 | 20 |
20 namespace views { | 21 namespace views { |
21 | 22 |
22 // An interface abstraction for Aura views that exposes the view-tree formed | 23 // An interface abstraction for Aura views that exposes the view-tree formed |
23 // by the implementing view types. | 24 // by the implementing view types. |
24 class VIEWS_EXPORT AXAuraObjWrapper { | 25 class VIEWS_EXPORT AXAuraObjWrapper { |
25 public: | 26 public: |
26 virtual ~AXAuraObjWrapper() {} | 27 virtual ~AXAuraObjWrapper() {} |
27 | 28 |
28 // Traversal and serialization. | 29 // Traversal and serialization. |
29 virtual AXAuraObjWrapper* GetParent() = 0; | 30 virtual AXAuraObjWrapper* GetParent() = 0; |
30 virtual void GetChildren( | 31 virtual void GetChildren( |
31 std::vector<AXAuraObjWrapper*>* out_children) = 0; | 32 std::vector<AXAuraObjWrapper*>* out_children) = 0; |
32 virtual void Serialize(ui::AXNodeData* out_node_data) = 0; | 33 virtual void Serialize(ui::AXNodeData* out_node_data) = 0; |
33 virtual int32 GetID() = 0; | 34 virtual int32_t GetID() = 0; |
34 | 35 |
35 // Actions. | 36 // Actions. |
36 virtual void DoDefault() {} | 37 virtual void DoDefault() {} |
37 virtual void Focus() {} | 38 virtual void Focus() {} |
38 virtual void MakeVisible() {} | 39 virtual void MakeVisible() {} |
39 virtual void SetSelection(int32 start, int32 end) {} | 40 virtual void SetSelection(int32_t start, int32_t end) {} |
40 virtual void ShowContextMenu() {} | 41 virtual void ShowContextMenu() {} |
41 }; | 42 }; |
42 | 43 |
43 } // namespace views | 44 } // namespace views |
44 | 45 |
45 #endif // UI_VIEWS_ACCESSIBILITY_AX_AURA_OBJ_WRAPPER_H_ | 46 #endif // UI_VIEWS_ACCESSIBILITY_AX_AURA_OBJ_WRAPPER_H_ |
OLD | NEW |