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 "base/strings/string_number_conversions.h" | 10 #include "base/strings/string_number_conversions.h" |
(...skipping 3795 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3806 break; | 3806 break; |
3807 case ui::AX_ROLE_TREE: | 3807 case ui::AX_ROLE_TREE: |
3808 ia_role_ = ROLE_SYSTEM_OUTLINE; | 3808 ia_role_ = ROLE_SYSTEM_OUTLINE; |
3809 break; | 3809 break; |
3810 case ui::AX_ROLE_TREE_GRID: | 3810 case ui::AX_ROLE_TREE_GRID: |
3811 ia_role_ = ROLE_SYSTEM_OUTLINE; | 3811 ia_role_ = ROLE_SYSTEM_OUTLINE; |
3812 break; | 3812 break; |
3813 case ui::AX_ROLE_TREE_ITEM: | 3813 case ui::AX_ROLE_TREE_ITEM: |
3814 ia_role_ = ROLE_SYSTEM_OUTLINEITEM; | 3814 ia_role_ = ROLE_SYSTEM_OUTLINEITEM; |
3815 break; | 3815 break; |
| 3816 case ui::AX_ROLE_LINE_BREAK: |
| 3817 ia_role_ = ROLE_SYSTEM_WHITESPACE; |
| 3818 break; |
3816 case ui::AX_ROLE_WINDOW: | 3819 case ui::AX_ROLE_WINDOW: |
3817 ia_role_ = ROLE_SYSTEM_WINDOW; | 3820 ia_role_ = ROLE_SYSTEM_WINDOW; |
3818 break; | 3821 break; |
3819 | 3822 |
3820 // TODO(dmazzoni): figure out the proper MSAA role for all of these. | 3823 // TODO(dmazzoni): figure out the proper MSAA role for all of these. |
3821 case ui::AX_ROLE_DIRECTORY: | 3824 case ui::AX_ROLE_DIRECTORY: |
3822 case ui::AX_ROLE_IGNORED: | 3825 case ui::AX_ROLE_IGNORED: |
3823 case ui::AX_ROLE_LOG: | 3826 case ui::AX_ROLE_LOG: |
3824 case ui::AX_ROLE_NONE: | 3827 case ui::AX_ROLE_NONE: |
3825 case ui::AX_ROLE_PRESENTATIONAL: | 3828 case ui::AX_ROLE_PRESENTATIONAL: |
(...skipping 21 matching lines...) Expand all Loading... |
3847 // The role should always be set. | 3850 // The role should always be set. |
3848 DCHECK(!role_name_.empty() || ia_role_); | 3851 DCHECK(!role_name_.empty() || ia_role_); |
3849 | 3852 |
3850 // If we didn't explicitly set the IAccessible2 role, make it the same | 3853 // If we didn't explicitly set the IAccessible2 role, make it the same |
3851 // as the MSAA role. | 3854 // as the MSAA role. |
3852 if (!ia2_role_) | 3855 if (!ia2_role_) |
3853 ia2_role_ = ia_role_; | 3856 ia2_role_ = ia_role_; |
3854 } | 3857 } |
3855 | 3858 |
3856 } // namespace content | 3859 } // namespace content |
OLD | NEW |