| 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_HOST_DELEGATE_H_ | 5 #ifndef UI_ACCESSIBILITY_AX_HOST_DELEGATE_H_ |
| 6 #define UI_ACCESSIBILITY_AX_HOST_DELEGATE_H_ | 6 #define UI_ACCESSIBILITY_AX_HOST_DELEGATE_H_ |
| 7 | 7 |
| 8 #include "ui/accessibility/ax_action_data.h" | 8 #include "ui/accessibility/ax_action_data.h" |
| 9 | 9 |
| 10 namespace ui { | 10 namespace ui { |
| (...skipping 14 matching lines...) Expand all Loading... |
| 25 protected: | 25 protected: |
| 26 // A delegate with an automatically assigned tree id. | 26 // A delegate with an automatically assigned tree id. |
| 27 AXHostDelegate(); | 27 AXHostDelegate(); |
| 28 | 28 |
| 29 // A delegate with an explicit tree id. The caller is responsible for ensuring | 29 // A delegate with an explicit tree id. The caller is responsible for ensuring |
| 30 // the uniqueness of the id. | 30 // the uniqueness of the id. |
| 31 explicit AXHostDelegate(int32_t tree_id); | 31 explicit AXHostDelegate(int32_t tree_id); |
| 32 | 32 |
| 33 // A tree id appropriate for annotating events sent to an accessibility | 33 // A tree id appropriate for annotating events sent to an accessibility |
| 34 // client. | 34 // client. |
| 35 int32_t tree_id() { return tree_id_; } | 35 int32_t tree_id() const { return tree_id_; } |
| 36 | 36 |
| 37 private: | 37 private: |
| 38 // Register or unregister this class with |AXTreeIDRegistry|. | 38 // Register or unregister this class with |AXTreeIDRegistry|. |
| 39 void UpdateActiveState(bool active); | 39 void UpdateActiveState(bool active); |
| 40 | 40 |
| 41 int32_t tree_id_; | 41 int32_t tree_id_; |
| 42 }; | 42 }; |
| 43 | 43 |
| 44 } // namespace ui | 44 } // namespace ui |
| 45 | 45 |
| 46 #endif // UI_ACCESSIBILITY_AX_HOST_DELEGATE_H_ | 46 #endif // UI_ACCESSIBILITY_AX_HOST_DELEGATE_H_ |
| OLD | NEW |