OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 "views/controls/menu/menu_scroll_view_container.h" | 5 #include "views/controls/menu/menu_scroll_view_container.h" |
6 | 6 |
7 #if defined(OS_WIN) | 7 #if defined(OS_WIN) |
8 #include <windows.h> | 8 #include <windows.h> |
9 #include <uxtheme.h> | 9 #include <uxtheme.h> |
10 #include <Vssym32.h> | 10 #include <Vssym32.h> |
(...skipping 256 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
267 return prefsize; | 267 return prefsize; |
268 } | 268 } |
269 | 269 |
270 bool MenuScrollViewContainer::GetAccessibleRole( | 270 bool MenuScrollViewContainer::GetAccessibleRole( |
271 AccessibilityTypes::Role* role) { | 271 AccessibilityTypes::Role* role) { |
272 DCHECK(role); | 272 DCHECK(role); |
273 *role = AccessibilityTypes::ROLE_MENUPOPUP; | 273 *role = AccessibilityTypes::ROLE_MENUPOPUP; |
274 return true; | 274 return true; |
275 } | 275 } |
276 | 276 |
| 277 bool MenuScrollViewContainer::GetAccessibleState( |
| 278 AccessibilityTypes::State* state) { |
| 279 DCHECK(state); |
| 280 // Some AT (like NVDA) will not process focus events on menu item children |
| 281 // unless a parent claims to be focused. |
| 282 *state = AccessibilityTypes::STATE_FOCUSED; |
| 283 return true; |
| 284 } |
| 285 |
277 } // namespace views | 286 } // namespace views |
OLD | NEW |