diff options
author | dmazzoni@chromium.org <dmazzoni@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-06 07:07:18 +0000 |
---|---|---|
committer | dmazzoni@chromium.org <dmazzoni@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-06 07:07:18 +0000 |
commit | 6a054ffaae82f5ac8d6b876d7c85f0d87d892e42 (patch) | |
tree | 86b4d5a0c5386f3d50742af099b5009ad1dad14d /views/view.cc | |
parent | 6ca800b9b2618e6ae4b92e189a9b1ae73746e49f (diff) | |
download | chromium_src-6a054ffaae82f5ac8d6b876d7c85f0d87d892e42.zip chromium_src-6a054ffaae82f5ac8d6b876d7c85f0d87d892e42.tar.gz chromium_src-6a054ffaae82f5ac8d6b876d7c85f0d87d892e42.tar.bz2 |
Improvements to accessibility extension api support for "views":
1. Handles the new wrench menu.
2. Uses NotifyAccessibilityEvent to find out when focus changes, rather
than installing focus change listeners that need to be cleaned up.
BUG=none
TEST=Updated AccessibilityEventRouterViewsTest.TestFocusNotification
Review URL: http://codereview.chromium.org/3056045
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@55196 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'views/view.cc')
-rw-r--r-- | views/view.cc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/views/view.cc b/views/view.cc index c8e35de..02d2766 100644 --- a/views/view.cc +++ b/views/view.cc @@ -314,6 +314,13 @@ void View::Focus() { FocusManager* focus_manager = GetFocusManager(); if (focus_manager) focus_manager->ClearNativeFocus(); + + // Notify assistive technologies of the focus change. + NotifyAccessibilityEvent(AccessibilityTypes::EVENT_FOCUS); +} + +void View::NotifyAccessibilityEvent(AccessibilityTypes::Event event_type) { + NotifyAccessibilityEvent(event_type, true); } void View::SetHotTracked(bool flag) { |