OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_PLATFORM_AX_PLATFORM_NODE_WIN_H_ | 5 #ifndef UI_ACCESSIBILITY_PLATFORM_AX_PLATFORM_NODE_WIN_H_ |
6 #define UI_ACCESSIBILITY_PLATFORM_AX_PLATFORM_NODE_WIN_H_ | 6 #define UI_ACCESSIBILITY_PLATFORM_AX_PLATFORM_NODE_WIN_H_ |
7 | 7 |
8 #include <atlbase.h> | 8 #include <atlbase.h> |
9 #include <atlcom.h> | 9 #include <atlcom.h> |
10 #include <oleacc.h> | 10 #include <oleacc.h> |
(...skipping 259 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
270 COM_INTERFACE_ENTRY(IAccessibleTable) | 270 COM_INTERFACE_ENTRY(IAccessibleTable) |
271 COM_INTERFACE_ENTRY(IAccessibleTable2) | 271 COM_INTERFACE_ENTRY(IAccessibleTable2) |
272 COM_INTERFACE_ENTRY(IAccessibleTableCell) | 272 COM_INTERFACE_ENTRY(IAccessibleTableCell) |
273 COM_INTERFACE_ENTRY(IServiceProvider) | 273 COM_INTERFACE_ENTRY(IServiceProvider) |
274 END_COM_MAP() | 274 END_COM_MAP() |
275 | 275 |
276 ~AXPlatformNodeWin() override; | 276 ~AXPlatformNodeWin() override; |
277 | 277 |
278 // Clear node's current relationships and set them to the default values. | 278 // Clear node's current relationships and set them to the default values. |
279 void CalculateRelationships(); | 279 void CalculateRelationships(); |
| 280 static AXPlatformNode* GetFromUniqueId(int32_t unique_id); |
| 281 int32_t unique_id() const { return unique_id_; } |
280 | 282 |
281 // AXPlatformNode overrides. | 283 // AXPlatformNode overrides. |
282 gfx::NativeViewAccessible GetNativeViewAccessible() override; | 284 gfx::NativeViewAccessible GetNativeViewAccessible() override; |
283 void NotifyAccessibilityEvent(ui::AXEvent event_type) override; | 285 void NotifyAccessibilityEvent(ui::AXEvent event_type) override; |
284 | 286 |
285 // AXPlatformNodeBase overrides. | 287 // AXPlatformNodeBase overrides. |
286 void Destroy() override; | 288 void Destroy() override; |
287 int GetIndexInParent() override; | 289 int GetIndexInParent() override; |
288 | 290 |
289 // | 291 // |
(...skipping 353 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
643 int32_t ComputeIA2State(); | 645 int32_t ComputeIA2State(); |
644 | 646 |
645 int32_t ComputeIA2Role(); | 647 int32_t ComputeIA2Role(); |
646 | 648 |
647 std::vector<base::string16> ComputeIA2Attributes(); | 649 std::vector<base::string16> ComputeIA2Attributes(); |
648 | 650 |
649 // AXPlatformNodeBase overrides. | 651 // AXPlatformNodeBase overrides. |
650 void Dispose() override; | 652 void Dispose() override; |
651 | 653 |
652 private: | 654 private: |
| 655 int32_t unique_id_; |
| 656 |
653 int MSAAEvent(ui::AXEvent event); | 657 int MSAAEvent(ui::AXEvent event); |
654 bool IsWebAreaForPresentationalIframe(); | 658 bool IsWebAreaForPresentationalIframe(); |
655 bool ShouldNodeHaveReadonlyStateByDefault(const AXNodeData& data) const; | 659 bool ShouldNodeHaveReadonlyStateByDefault(const AXNodeData& data) const; |
656 bool ShouldNodeHaveFocusableState(const AXNodeData& data) const; | 660 bool ShouldNodeHaveFocusableState(const AXNodeData& data) const; |
657 | 661 |
658 HRESULT GetStringAttributeAsBstr( | 662 HRESULT GetStringAttributeAsBstr( |
659 ui::AXStringAttribute attribute, | 663 ui::AXStringAttribute attribute, |
660 BSTR* value_bstr) const; | 664 BSTR* value_bstr) const; |
661 | 665 |
662 // Escapes characters in string attributes as required by the IA2 Spec. | 666 // Escapes characters in string attributes as required by the IA2 Spec. |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
736 void RemoveTargetFromRelation(const base::string16& relation_type, | 740 void RemoveTargetFromRelation(const base::string16& relation_type, |
737 int target_id); | 741 int target_id); |
738 | 742 |
739 // Relationships between this node and other nodes. | 743 // Relationships between this node and other nodes. |
740 std::vector<ui::AXPlatformNodeRelationWin*> relations_; | 744 std::vector<ui::AXPlatformNodeRelationWin*> relations_; |
741 }; | 745 }; |
742 | 746 |
743 } // namespace ui | 747 } // namespace ui |
744 | 748 |
745 #endif // UI_ACCESSIBILITY_PLATFORM_AX_PLATFORM_NODE_WIN_H_ | 749 #endif // UI_ACCESSIBILITY_PLATFORM_AX_PLATFORM_NODE_WIN_H_ |
OLD | NEW |