OLD | NEW |
1 // Copyright (c) 2017 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_COM_WIN_H_ | 5 #ifndef CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_COM_WIN_H_ |
6 #define CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_COM_WIN_H_ | 6 #define CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_COM_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 709 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
720 | 720 |
721 // Public accessors (these do not have COM accessible accessors) | 721 // Public accessors (these do not have COM accessible accessors) |
722 const base::string16& role_name() const { return win_attributes_->role_name; } | 722 const base::string16& role_name() const { return win_attributes_->role_name; } |
723 const std::map<int, std::vector<base::string16>>& offset_to_text_attributes() | 723 const std::map<int, std::vector<base::string16>>& offset_to_text_attributes() |
724 const { | 724 const { |
725 return win_attributes_->offset_to_text_attributes; | 725 return win_attributes_->offset_to_text_attributes; |
726 } | 726 } |
727 | 727 |
728 private: | 728 private: |
729 // Private accessors. | 729 // Private accessors. |
730 int32_t ia_role() const { return win_attributes_->ia_role; } | |
731 int32_t ia2_role() const { return win_attributes_->ia2_role; } | 730 int32_t ia2_role() const { return win_attributes_->ia2_role; } |
732 int32_t ia2_state() const { return win_attributes_->ia2_state; } | 731 int32_t ia2_state() const { return win_attributes_->ia2_state; } |
733 const std::vector<base::string16>& ia2_attributes() const { | 732 const std::vector<base::string16>& ia2_attributes() const { |
734 return win_attributes_->ia2_attributes; | 733 return win_attributes_->ia2_attributes; |
735 } | 734 } |
736 base::string16 name() const { return win_attributes_->name; } | 735 base::string16 name() const { return win_attributes_->name; } |
737 base::string16 description() const { return win_attributes_->description; } | 736 base::string16 description() const { return win_attributes_->description; } |
738 base::string16 value() const { return win_attributes_->value; } | 737 base::string16 value() const { return win_attributes_->value; } |
739 | 738 |
740 std::map<int32_t, int32_t>& hyperlink_offset_to_index() const { | 739 std::map<int32_t, int32_t>& hyperlink_offset_to_index() const { |
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
919 const base::string16& relation_type, | 918 const base::string16& relation_type, |
920 const base::string16& reverse_relation_type); | 919 const base::string16& reverse_relation_type); |
921 void RemoveTargetFromRelation(const base::string16& relation_type, | 920 void RemoveTargetFromRelation(const base::string16& relation_type, |
922 int target_id); | 921 int target_id); |
923 | 922 |
924 // Updates object attributes of IA2 with html attributes. | 923 // Updates object attributes of IA2 with html attributes. |
925 void UpdateRequiredAttributes(); | 924 void UpdateRequiredAttributes(); |
926 | 925 |
927 // Fire a Windows-specific accessibility event notification on this node. | 926 // Fire a Windows-specific accessibility event notification on this node. |
928 void FireNativeEvent(LONG win_event_type) const; | 927 void FireNativeEvent(LONG win_event_type) const; |
929 | |
930 static bool IsInTreeGrid(const BrowserAccessibility* item); | |
931 | |
932 struct WinAttributes { | 928 struct WinAttributes { |
933 WinAttributes(); | 929 WinAttributes(); |
934 ~WinAttributes(); | 930 ~WinAttributes(); |
935 | 931 |
936 // IAccessible role and state. | 932 // IAccessible role and state. |
937 int32_t ia_role; | 933 int32_t ia_role; |
938 int32_t ia_state; | 934 int32_t ia_state; |
939 base::string16 role_name; | 935 base::string16 role_name; |
940 | 936 |
941 // IAccessible name, description, help, value. | 937 // IAccessible name, description, help, value. |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
989 | 985 |
990 DISALLOW_COPY_AND_ASSIGN(BrowserAccessibilityComWin); | 986 DISALLOW_COPY_AND_ASSIGN(BrowserAccessibilityComWin); |
991 }; | 987 }; |
992 | 988 |
993 CONTENT_EXPORT BrowserAccessibilityComWin* ToBrowserAccessibilityComWin( | 989 CONTENT_EXPORT BrowserAccessibilityComWin* ToBrowserAccessibilityComWin( |
994 BrowserAccessibility* obj); | 990 BrowserAccessibility* obj); |
995 | 991 |
996 } // namespace content | 992 } // namespace content |
997 | 993 |
998 #endif // CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_COM_WIN_H_ | 994 #endif // CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_COM_WIN_H_ |
OLD | NEW |