From 434c0eb886cf13bcaa77652c9bfb104dc04f5e9e Mon Sep 17 00:00:00 2001 From: "dmazzoni@chromium.org" Date: Wed, 24 Mar 2010 14:27:08 +0000 Subject: Keyboard accessibility for the page and app menus. Works on Windows, and on Linux with toolkit_views. The goal is to make Chrome behave more like a standard Windows application, for users who rely on the keyboard and expect standard keyboard accelerators to work. Pressing F10, or pressing and releasing Alt, will set focus to the Page menu, as if it was the first item in a menu bar. Pressing enter, space, up arrow, or down arrow will open the focused menu. Once a menu is opened, pressing left and right arrows will switch between the two menus. Pressing escape will return focus to the title of the previously open menu. A new UI test attempts to select something from the menus using only the keyboard. It works on Linux (with toolkit_views) and on Windows. BUG=none TEST=New keyboard accessibility ui test. Review URL: http://codereview.chromium.org/660323 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42465 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/test/automation/browser_proxy.h | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'chrome/test/automation/browser_proxy.h') diff --git a/chrome/test/automation/browser_proxy.h b/chrome/test/automation/browser_proxy.h index a21bfe6..509a630 100644 --- a/chrome/test/automation/browser_proxy.h +++ b/chrome/test/automation/browser_proxy.h @@ -217,6 +217,15 @@ class BrowserProxy : public AutomationResourceProxy { // on success. bool ShutdownSessionService() WARN_UNUSED_RESULT; + // To avoid race conditions, waiting until a popup menu opens is a + // three-step process: + // 1. Call StartTrackingPopupMenus. + // 2. Call an automation method that results in opening the popup menu. + // 3. Call WaitForPopupMenuToOpen and check for success. + // Both methods return true on success. + bool StartTrackingPopupMenus() WARN_UNUSED_RESULT; + bool WaitForPopupMenuToOpen() WARN_UNUSED_RESULT; + protected: virtual ~BrowserProxy() {} private: -- cgit v1.1