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 22 matching lines...) Expand all Loading... |
33 extern AX_EXPORT base::ObserverList<IAccessible2UsageObserver>& | 33 extern AX_EXPORT base::ObserverList<IAccessible2UsageObserver>& |
34 GetIAccessible2UsageObserverList(); | 34 GetIAccessible2UsageObserverList(); |
35 | 35 |
36 class AX_EXPORT __declspec(uuid("26f5641a-246d-457b-a96d-07f3fae6acf2")) | 36 class AX_EXPORT __declspec(uuid("26f5641a-246d-457b-a96d-07f3fae6acf2")) |
37 AXPlatformNodeWin | 37 AXPlatformNodeWin |
38 : public NON_EXPORTED_BASE(CComObjectRootEx<CComMultiThreadModel>), | 38 : public NON_EXPORTED_BASE(CComObjectRootEx<CComMultiThreadModel>), |
39 public IDispatchImpl<IAccessible2_2, | 39 public IDispatchImpl<IAccessible2_2, |
40 &IID_IAccessible2, | 40 &IID_IAccessible2, |
41 &LIBID_IAccessible2Lib>, | 41 &LIBID_IAccessible2Lib>, |
42 public IAccessibleText, | 42 public IAccessibleText, |
| 43 public IAccessibleTable, |
| 44 public IAccessibleTable2, |
| 45 public IAccessibleTableCell, |
43 public IServiceProvider, | 46 public IServiceProvider, |
44 public AXPlatformNodeBase { | 47 public AXPlatformNodeBase { |
45 public: | 48 public: |
46 BEGIN_COM_MAP(AXPlatformNodeWin) | 49 BEGIN_COM_MAP(AXPlatformNodeWin) |
47 COM_INTERFACE_ENTRY2(IDispatch, IAccessible2_2) | 50 COM_INTERFACE_ENTRY2(IDispatch, IAccessible2_2) |
48 COM_INTERFACE_ENTRY(AXPlatformNodeWin) | 51 COM_INTERFACE_ENTRY(AXPlatformNodeWin) |
49 COM_INTERFACE_ENTRY(IAccessible) | 52 COM_INTERFACE_ENTRY(IAccessible) |
50 COM_INTERFACE_ENTRY(IAccessible2) | 53 COM_INTERFACE_ENTRY(IAccessible2) |
51 COM_INTERFACE_ENTRY(IAccessible2_2) | 54 COM_INTERFACE_ENTRY(IAccessible2_2) |
52 COM_INTERFACE_ENTRY(IAccessibleText) | 55 COM_INTERFACE_ENTRY(IAccessibleText) |
| 56 COM_INTERFACE_ENTRY(IAccessibleTable) |
| 57 COM_INTERFACE_ENTRY(IAccessibleTable2) |
| 58 COM_INTERFACE_ENTRY(IAccessibleTableCell) |
53 COM_INTERFACE_ENTRY(IServiceProvider) | 59 COM_INTERFACE_ENTRY(IServiceProvider) |
54 END_COM_MAP() | 60 END_COM_MAP() |
55 | 61 |
56 ~AXPlatformNodeWin() override; | 62 ~AXPlatformNodeWin() override; |
57 | 63 |
58 // AXPlatformNode overrides. | 64 // AXPlatformNode overrides. |
59 gfx::NativeViewAccessible GetNativeViewAccessible() override; | 65 gfx::NativeViewAccessible GetNativeViewAccessible() override; |
60 void NotifyAccessibilityEvent(ui::AXEvent event_type) override; | 66 void NotifyAccessibilityEvent(ui::AXEvent event_type) override; |
61 | 67 |
62 // AXPlatformNodeBase overrides. | 68 // AXPlatformNodeBase overrides. |
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
221 LONG* start_offset, | 227 LONG* start_offset, |
222 LONG* end_offset, | 228 LONG* end_offset, |
223 BSTR* text) override; | 229 BSTR* text) override; |
224 | 230 |
225 STDMETHODIMP get_offsetAtPoint(LONG x, | 231 STDMETHODIMP get_offsetAtPoint(LONG x, |
226 LONG y, | 232 LONG y, |
227 enum IA2CoordinateType coord_type, | 233 enum IA2CoordinateType coord_type, |
228 LONG* offset) override; | 234 LONG* offset) override; |
229 | 235 |
230 // | 236 // |
| 237 // IAccessibleTable methods. |
| 238 // |
| 239 |
| 240 // get_description - also used by IAccessibleImage |
| 241 |
| 242 STDMETHODIMP get_accessibleAt(long row, |
| 243 long column, |
| 244 IUnknown** accessible) override; |
| 245 |
| 246 STDMETHODIMP get_caption(IUnknown** accessible) override; |
| 247 |
| 248 STDMETHODIMP get_childIndex(long row_index, |
| 249 long column_index, |
| 250 long* cell_index) override; |
| 251 |
| 252 STDMETHODIMP get_columnDescription(long column, BSTR* description) override; |
| 253 |
| 254 STDMETHODIMP |
| 255 get_columnExtentAt(long row, long column, long* n_columns_spanned) override; |
| 256 |
| 257 STDMETHODIMP |
| 258 get_columnHeader(IAccessibleTable** accessible_table, |
| 259 long* starting_row_index) override; |
| 260 |
| 261 STDMETHODIMP get_columnIndex(long cell_index, long* column_index) override; |
| 262 |
| 263 STDMETHODIMP get_nColumns(long* column_count) override; |
| 264 |
| 265 STDMETHODIMP get_nRows(long* row_count) override; |
| 266 |
| 267 STDMETHODIMP get_nSelectedChildren(long* cell_count) override; |
| 268 |
| 269 STDMETHODIMP get_nSelectedColumns(long* column_count) override; |
| 270 |
| 271 STDMETHODIMP get_nSelectedRows(long* row_count) override; |
| 272 |
| 273 STDMETHODIMP get_rowDescription(long row, BSTR* description) override; |
| 274 |
| 275 STDMETHODIMP get_rowExtentAt(long row, |
| 276 long column, |
| 277 long* n_rows_spanned) override; |
| 278 |
| 279 STDMETHODIMP |
| 280 get_rowHeader(IAccessibleTable** accessible_table, |
| 281 long* starting_column_index) override; |
| 282 |
| 283 STDMETHODIMP get_rowIndex(long cell_index, long* row_index) override; |
| 284 |
| 285 STDMETHODIMP get_selectedChildren(long max_children, |
| 286 long** children, |
| 287 long* n_children) override; |
| 288 |
| 289 STDMETHODIMP get_selectedColumns(long max_columns, |
| 290 long** columns, |
| 291 long* n_columns) override; |
| 292 |
| 293 STDMETHODIMP get_selectedRows(long max_rows, |
| 294 long** rows, |
| 295 long* n_rows) override; |
| 296 |
| 297 STDMETHODIMP get_summary(IUnknown** accessible) override; |
| 298 |
| 299 STDMETHODIMP |
| 300 get_isColumnSelected(long column, boolean* is_selected) override; |
| 301 |
| 302 STDMETHODIMP get_isRowSelected(long row, boolean* is_selected) override; |
| 303 |
| 304 STDMETHODIMP get_isSelected(long row, |
| 305 long column, |
| 306 boolean* is_selected) override; |
| 307 |
| 308 STDMETHODIMP |
| 309 get_rowColumnExtentsAtIndex(long index, |
| 310 long* row, |
| 311 long* column, |
| 312 long* row_extents, |
| 313 long* column_extents, |
| 314 boolean* is_selected) override; |
| 315 |
| 316 STDMETHODIMP selectRow(long row) override; |
| 317 |
| 318 STDMETHODIMP selectColumn(long column) override; |
| 319 |
| 320 STDMETHODIMP unselectRow(long row) override; |
| 321 |
| 322 STDMETHODIMP unselectColumn(long column) override; |
| 323 |
| 324 STDMETHODIMP |
| 325 get_modelChange(IA2TableModelChange* model_change) override; |
| 326 |
| 327 // |
| 328 // IAccessibleTable2 methods. |
| 329 // |
| 330 // (Most of these are duplicates of IAccessibleTable methods, only the |
| 331 // unique ones are included here.) |
| 332 // |
| 333 |
| 334 STDMETHODIMP get_cellAt(long row, long column, IUnknown** cell) override; |
| 335 |
| 336 STDMETHODIMP get_nSelectedCells(long* cell_count) override; |
| 337 |
| 338 STDMETHODIMP |
| 339 get_selectedCells(IUnknown*** cells, long* n_selected_cells) override; |
| 340 |
| 341 STDMETHODIMP get_selectedColumns(long** columns, long* n_columns) override; |
| 342 |
| 343 STDMETHODIMP get_selectedRows(long** rows, long* n_rows) override; |
| 344 |
| 345 // |
| 346 // IAccessibleTableCell methods. |
| 347 // |
| 348 |
| 349 STDMETHODIMP |
| 350 get_columnExtent(long* n_columns_spanned) override; |
| 351 |
| 352 STDMETHODIMP |
| 353 get_columnHeaderCells(IUnknown*** cell_accessibles, |
| 354 long* n_column_header_cells) override; |
| 355 |
| 356 STDMETHODIMP get_columnIndex(long* column_index) override; |
| 357 |
| 358 STDMETHODIMP get_rowExtent(long* n_rows_spanned) override; |
| 359 |
| 360 STDMETHODIMP |
| 361 get_rowHeaderCells(IUnknown*** cell_accessibles, |
| 362 long* n_row_header_cells) override; |
| 363 |
| 364 STDMETHODIMP get_rowIndex(long* row_index) override; |
| 365 |
| 366 STDMETHODIMP get_isSelected(boolean* is_selected) override; |
| 367 |
| 368 STDMETHODIMP |
| 369 get_rowColumnExtents(long* row, |
| 370 long* column, |
| 371 long* row_extents, |
| 372 long* column_extents, |
| 373 boolean* is_selected) override; |
| 374 |
| 375 STDMETHODIMP get_table(IUnknown** table) override; |
| 376 |
| 377 // |
231 // IAccessibleText methods not implemented. | 378 // IAccessibleText methods not implemented. |
232 // | 379 // |
233 | 380 |
234 STDMETHODIMP get_newText(IA2TextSegment* new_text) override; | 381 STDMETHODIMP get_newText(IA2TextSegment* new_text) override; |
235 STDMETHODIMP get_oldText(IA2TextSegment* old_text) override; | 382 STDMETHODIMP get_oldText(IA2TextSegment* old_text) override; |
236 STDMETHODIMP addSelection(LONG start_offset, LONG end_offset) override; | 383 STDMETHODIMP addSelection(LONG start_offset, LONG end_offset) override; |
237 STDMETHODIMP get_attributes(LONG offset, | 384 STDMETHODIMP get_attributes(LONG offset, |
238 LONG* start_offset, | 385 LONG* start_offset, |
239 LONG* end_offset, | 386 LONG* end_offset, |
240 BSTR* text_attributes) override; | 387 BSTR* text_attributes) override; |
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
310 // should be performed on a particular child ID, rather than this object. | 457 // should be performed on a particular child ID, rather than this object. |
311 // This method tries to figure out the target object from |var_id| and | 458 // This method tries to figure out the target object from |var_id| and |
312 // returns a pointer to the target object if it exists, otherwise nullptr. | 459 // returns a pointer to the target object if it exists, otherwise nullptr. |
313 // Does not return a new reference. | 460 // Does not return a new reference. |
314 AXPlatformNodeWin* GetTargetFromChildID(const VARIANT& var_id); | 461 AXPlatformNodeWin* GetTargetFromChildID(const VARIANT& var_id); |
315 }; | 462 }; |
316 | 463 |
317 } // namespace ui | 464 } // namespace ui |
318 | 465 |
319 #endif // UI_ACCESSIBILITY_PLATFORM_AX_PLATFORM_NODE_WIN_H_ | 466 #endif // UI_ACCESSIBILITY_PLATFORM_AX_PLATFORM_NODE_WIN_H_ |
OLD | NEW |