OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "content/browser/accessibility/browser_accessibility_win.h" | 5 #include "content/browser/accessibility/browser_accessibility_win.h" |
6 | 6 |
7 #include <UIAutomationClient.h> | 7 #include <UIAutomationClient.h> |
8 #include <UIAutomationCoreApi.h> | 8 #include <UIAutomationCoreApi.h> |
9 | 9 |
10 #include <algorithm> | 10 #include <algorithm> |
(...skipping 5320 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
5331 | 5331 |
5332 base::string16 html_tag = GetString16Attribute( | 5332 base::string16 html_tag = GetString16Attribute( |
5333 ui::AX_ATTR_HTML_TAG); | 5333 ui::AX_ATTR_HTML_TAG); |
5334 switch (GetRole()) { | 5334 switch (GetRole()) { |
5335 case ui::AX_ROLE_ALERT: | 5335 case ui::AX_ROLE_ALERT: |
5336 ia_role = ROLE_SYSTEM_ALERT; | 5336 ia_role = ROLE_SYSTEM_ALERT; |
5337 break; | 5337 break; |
5338 case ui::AX_ROLE_ALERT_DIALOG: | 5338 case ui::AX_ROLE_ALERT_DIALOG: |
5339 ia_role = ROLE_SYSTEM_DIALOG; | 5339 ia_role = ROLE_SYSTEM_DIALOG; |
5340 break; | 5340 break; |
5341 case ui::AX_ROLE_ANCHOR: | |
David Tseng
2017/04/03 17:20:18
Note that ChromeVox needs something like this in
c
| |
5342 ia_role = ROLE_SYSTEM_LINK; | |
5343 break; | |
5341 case ui::AX_ROLE_APPLICATION: | 5344 case ui::AX_ROLE_APPLICATION: |
5342 ia_role = ROLE_SYSTEM_APPLICATION; | 5345 ia_role = ROLE_SYSTEM_APPLICATION; |
5343 break; | 5346 break; |
5344 case ui::AX_ROLE_ARTICLE: | 5347 case ui::AX_ROLE_ARTICLE: |
5345 ia_role = ROLE_SYSTEM_DOCUMENT; | 5348 ia_role = ROLE_SYSTEM_DOCUMENT; |
5346 ia_state |= STATE_SYSTEM_READONLY; | 5349 ia_state |= STATE_SYSTEM_READONLY; |
5347 break; | 5350 break; |
5348 case ui::AX_ROLE_AUDIO: | 5351 case ui::AX_ROLE_AUDIO: |
5349 ia_role = ROLE_SYSTEM_GROUPING; | 5352 ia_role = ROLE_SYSTEM_GROUPING; |
5350 break; | 5353 break; |
(...skipping 482 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
5833 return static_cast<BrowserAccessibilityWin*>(obj); | 5836 return static_cast<BrowserAccessibilityWin*>(obj); |
5834 } | 5837 } |
5835 | 5838 |
5836 const BrowserAccessibilityWin* | 5839 const BrowserAccessibilityWin* |
5837 ToBrowserAccessibilityWin(const BrowserAccessibility* obj) { | 5840 ToBrowserAccessibilityWin(const BrowserAccessibility* obj) { |
5838 DCHECK(!obj || obj->IsNative()); | 5841 DCHECK(!obj || obj->IsNative()); |
5839 return static_cast<const BrowserAccessibilityWin*>(obj); | 5842 return static_cast<const BrowserAccessibilityWin*>(obj); |
5840 } | 5843 } |
5841 | 5844 |
5842 } // namespace content | 5845 } // namespace content |
OLD | NEW |