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 #include <atlbase.h> | 5 #include <atlbase.h> |
6 #include <atlcom.h> | 6 #include <atlcom.h> |
7 #include <limits.h> | 7 #include <limits.h> |
8 #include <oleacc.h> | 8 #include <oleacc.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
(...skipping 912 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
923 return S_OK; | 923 return S_OK; |
924 } | 924 } |
925 | 925 |
926 // | 926 // |
927 // IAccessible2 methods not implemented. | 927 // IAccessible2 methods not implemented. |
928 // | 928 // |
929 | 929 |
930 STDMETHODIMP AXPlatformNodeWin::get_attribute(BSTR name, VARIANT* attribute) { | 930 STDMETHODIMP AXPlatformNodeWin::get_attribute(BSTR name, VARIANT* attribute) { |
931 return E_NOTIMPL; | 931 return E_NOTIMPL; |
932 } | 932 } |
933 | |
933 STDMETHODIMP AXPlatformNodeWin::get_extendedRole(BSTR* extended_role) { | 934 STDMETHODIMP AXPlatformNodeWin::get_extendedRole(BSTR* extended_role) { |
935 WIN_ACCESSIBILITY_API_HISTOGRAM(UMA_API_GET_EXTENDED_ROLE); | |
dmazzoni
2017/07/17 08:32:40
Wait, how does this even compile if this macro is
| |
934 return E_NOTIMPL; | 936 return E_NOTIMPL; |
935 } | 937 } |
938 | |
936 STDMETHODIMP AXPlatformNodeWin::get_nRelations(LONG* n_relations) { | 939 STDMETHODIMP AXPlatformNodeWin::get_nRelations(LONG* n_relations) { |
937 return E_NOTIMPL; | 940 return E_NOTIMPL; |
938 } | 941 } |
942 | |
939 STDMETHODIMP AXPlatformNodeWin::get_relation(LONG relation_index, | 943 STDMETHODIMP AXPlatformNodeWin::get_relation(LONG relation_index, |
940 IAccessibleRelation** relation) { | 944 IAccessibleRelation** relation) { |
941 return E_NOTIMPL; | 945 return E_NOTIMPL; |
942 } | 946 } |
947 | |
943 STDMETHODIMP AXPlatformNodeWin::get_relations(LONG max_relations, | 948 STDMETHODIMP AXPlatformNodeWin::get_relations(LONG max_relations, |
944 IAccessibleRelation** relations, | 949 IAccessibleRelation** relations, |
945 LONG* n_relations) { | 950 LONG* n_relations) { |
946 return E_NOTIMPL; | 951 return E_NOTIMPL; |
947 } | 952 } |
953 | |
948 STDMETHODIMP AXPlatformNodeWin::scrollTo(enum IA2ScrollType scroll_type) { | 954 STDMETHODIMP AXPlatformNodeWin::scrollTo(enum IA2ScrollType scroll_type) { |
949 return E_NOTIMPL; | 955 return E_NOTIMPL; |
950 } | 956 } |
957 | |
951 STDMETHODIMP AXPlatformNodeWin::scrollToPoint( | 958 STDMETHODIMP AXPlatformNodeWin::scrollToPoint( |
952 enum IA2CoordinateType coordinate_type, | 959 enum IA2CoordinateType coordinate_type, |
953 LONG x, | 960 LONG x, |
954 LONG y) { | 961 LONG y) { |
955 return E_NOTIMPL; | 962 return E_NOTIMPL; |
956 } | 963 } |
964 | |
957 STDMETHODIMP AXPlatformNodeWin::get_groupPosition(LONG* group_level, | 965 STDMETHODIMP AXPlatformNodeWin::get_groupPosition(LONG* group_level, |
958 LONG* similar_items_in_group, | 966 LONG* similar_items_in_group, |
959 LONG* position_in_group) { | 967 LONG* position_in_group) { |
960 return E_NOTIMPL; | 968 return E_NOTIMPL; |
961 } | 969 } |
970 | |
962 STDMETHODIMP AXPlatformNodeWin::get_localizedExtendedRole( | 971 STDMETHODIMP AXPlatformNodeWin::get_localizedExtendedRole( |
963 BSTR* localized_extended_role) { | 972 BSTR* localized_extended_role) { |
964 return E_NOTIMPL; | 973 return E_NOTIMPL; |
965 } | 974 } |
975 | |
966 STDMETHODIMP AXPlatformNodeWin::get_nExtendedStates(LONG* n_extended_states) { | 976 STDMETHODIMP AXPlatformNodeWin::get_nExtendedStates(LONG* n_extended_states) { |
977 WIN_ACCESSIBILITY_API_HISTOGRAM(UMA_API_GET_N_EXTENDED_STATES); | |
967 return E_NOTIMPL; | 978 return E_NOTIMPL; |
968 } | 979 } |
980 | |
969 STDMETHODIMP AXPlatformNodeWin::get_extendedStates(LONG max_extended_states, | 981 STDMETHODIMP AXPlatformNodeWin::get_extendedStates(LONG max_extended_states, |
970 BSTR** extended_states, | 982 BSTR** extended_states, |
971 LONG* n_extended_states) { | 983 LONG* n_extended_states) { |
984 WIN_ACCESSIBILITY_API_HISTOGRAM(UMA_API_GET_EXTENDED_STATES); | |
972 return E_NOTIMPL; | 985 return E_NOTIMPL; |
973 } | 986 } |
987 | |
974 STDMETHODIMP AXPlatformNodeWin::get_localizedExtendedStates( | 988 STDMETHODIMP AXPlatformNodeWin::get_localizedExtendedStates( |
975 LONG max_localized_extended_states, | 989 LONG max_localized_extended_states, |
976 BSTR** localized_extended_states, | 990 BSTR** localized_extended_states, |
977 LONG* n_localized_extended_states) { | 991 LONG* n_localized_extended_states) { |
992 WIN_ACCESSIBILITY_API_HISTOGRAM(UMA_API_GET_LOCALIZED_EXTENDED_STATES); | |
993 | |
978 return E_NOTIMPL; | 994 return E_NOTIMPL; |
979 } | 995 } |
996 | |
980 STDMETHODIMP AXPlatformNodeWin::get_locale(IA2Locale* locale) { | 997 STDMETHODIMP AXPlatformNodeWin::get_locale(IA2Locale* locale) { |
998 WIN_ACCESSIBILITY_API_HISTOGRAM(UMA_API_GET_LOCALE); | |
981 return E_NOTIMPL; | 999 return E_NOTIMPL; |
982 } | 1000 } |
1001 | |
983 STDMETHODIMP AXPlatformNodeWin::get_accessibleWithCaret(IUnknown** accessible, | 1002 STDMETHODIMP AXPlatformNodeWin::get_accessibleWithCaret(IUnknown** accessible, |
984 long* caret_offset) { | 1003 long* caret_offset) { |
985 return E_NOTIMPL; | 1004 return E_NOTIMPL; |
986 } | 1005 } |
987 | 1006 |
988 // | 1007 // |
989 // IAccessibleTable methods. | 1008 // IAccessibleTable methods. |
990 // | 1009 // |
991 | 1010 |
992 STDMETHODIMP AXPlatformNodeWin::get_accessibleAt(long row, | 1011 STDMETHODIMP AXPlatformNodeWin::get_accessibleAt(long row, |
(...skipping 828 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1821 REFGUID guidService, REFIID riid, void** object) { | 1840 REFGUID guidService, REFIID riid, void** object) { |
1822 COM_OBJECT_VALIDATE_1_ARG(object); | 1841 COM_OBJECT_VALIDATE_1_ARG(object); |
1823 | 1842 |
1824 if (riid == IID_IAccessible2) { | 1843 if (riid == IID_IAccessible2) { |
1825 for (IAccessible2UsageObserver& observer : | 1844 for (IAccessible2UsageObserver& observer : |
1826 GetIAccessible2UsageObserverList()) { | 1845 GetIAccessible2UsageObserverList()) { |
1827 observer.OnIAccessible2Used(); | 1846 observer.OnIAccessible2Used(); |
1828 } | 1847 } |
1829 } | 1848 } |
1830 | 1849 |
1831 if (guidService == IID_IAccessible || | 1850 if (guidService == IID_IAccessible || guidService == IID_IAccessible2 || |
1832 guidService == IID_IAccessible2 || | |
1833 guidService == IID_IAccessible2_2 || | 1851 guidService == IID_IAccessible2_2 || |
1852 guidService == IID_IAccessibleTable || | |
1853 guidService == IID_IAccessibleTable2 || | |
1854 guidService == IID_IAccessibleTableCell || | |
1834 guidService == IID_IAccessibleText) { | 1855 guidService == IID_IAccessibleText) { |
1835 return QueryInterface(riid, object); | 1856 return QueryInterface(riid, object); |
1836 } | 1857 } |
1837 | 1858 |
1838 *object = nullptr; | 1859 *object = nullptr; |
1839 return E_FAIL; | 1860 return E_FAIL; |
1840 } | 1861 } |
1841 | 1862 |
1842 // | 1863 // |
1843 // Private member functions. | 1864 // Private member functions. |
(...skipping 955 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2799 if (container && container->GetData().role == ui::AX_ROLE_GROUP) | 2820 if (container && container->GetData().role == ui::AX_ROLE_GROUP) |
2800 container = FromNativeViewAccessible(container->GetParent()); | 2821 container = FromNativeViewAccessible(container->GetParent()); |
2801 | 2822 |
2802 if (!container) | 2823 if (!container) |
2803 return false; | 2824 return false; |
2804 | 2825 |
2805 return container->GetData().role == ui::AX_ROLE_TREE_GRID; | 2826 return container->GetData().role == ui::AX_ROLE_TREE_GRID; |
2806 } | 2827 } |
2807 | 2828 |
2808 } // namespace ui | 2829 } // namespace ui |
OLD | NEW |