OLD | NEW |
(Empty) | |
| 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_NODE_POSITION_H_ |
| 6 #define UI_ACCESSIBILITY_AX_NODE_POSITION_H_ |
| 7 |
| 8 #include <stdint.h> |
| 9 |
| 10 #include "ui/accessibility/ax_export.h" |
| 11 #include "ui/accessibility/ax_node.h" |
| 12 #include "ui/accessibility/ax_position.h" |
| 13 #include "ui/accessibility/ax_tree.h" |
| 14 |
| 15 namespace ui { |
| 16 |
| 17 class AX_EXPORT AXNodePosition : public AXPosition<AXNodePosition, AXNode> { |
| 18 public: |
| 19 AXNodePosition(); |
| 20 ~AXNodePosition() override; |
| 21 |
| 22 AXTree* get_tree() const { return tree_; } |
| 23 void set_tree(AXTree* tree) { tree_ = tree; } |
| 24 |
| 25 protected: |
| 26 int AnchorChildCount() const override; |
| 27 AXNodePosition* GetChildPositionAt(int child_index) const override; |
| 28 AXNodePosition* GetParentPosition() const override; |
| 29 int AnchorIndexInParent() const override; |
| 30 AXNode* GetNodeInTree(int tree_id, int32_t node_id) const override; |
| 31 int MaxTextOffset() const override; |
| 32 |
| 33 private: |
| 34 AXTree* tree_; |
| 35 }; |
| 36 |
| 37 } // namespace ui |
| 38 |
| 39 #endif // UI_ACCESSIBILITY_AX_NODE_POSITION_H_ |
OLD | NEW |