Skip to content
Snippets Groups Projects
Commit d5c7934b authored by sky@chromium.org's avatar sky@chromium.org
Browse files

Enables the new wrench menu by default on windows.

BUG=45734
TEST=make sure the new wrench menu works! Make sure and exer

Review URL: http://codereview.chromium.org/2845022

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@50893 0039d316-1c4b-4281-b951-d872f2087c98
parent d1402b27
No related branches found
No related tags found
No related merge requests found
......@@ -12,6 +12,7 @@
#include "chrome/browser/views/bookmark_bar_view.h"
#include "chrome/browser/views/frame/browser_view.h"
#include "chrome/browser/views/toolbar_view.h"
#include "chrome/browser/wrench_menu_model.h"
#include "chrome/common/url_constants.h"
#include "chrome/test/in_process_browser_test.h"
#include "chrome/test/ui_test_utils.h"
......@@ -224,6 +225,9 @@ IN_PROC_BROWSER_TEST_F(BrowserViewsAccessibilityTest,
// Retrieve accessibility object for Page menu button and verify accessibility
// info.
IN_PROC_BROWSER_TEST_F(BrowserViewsAccessibilityTest, TestPageMenuAccObj) {
if (WrenchMenuModel::IsEnabled())
return; // If the wrench menu is enabled there is no page menu.
// Verify Page menu button MSAA name and role.
TestViewAccessibilityObject(GetToolbarView()->GetViewByID(VIEW_ID_PAGE_MENU),
l10n_util::GetString(IDS_ACCNAME_PAGE),
......
......@@ -75,7 +75,11 @@ static bool CalculateEnabled() {
std::string value = cl->GetSwitchValueASCII(switches::kNewWrenchMenu);
return value.empty() || value == "true";
}
#if defined(TOOLKIT_VIEWS)
return true;
#else
return false;
#endif
}
// static
......
......@@ -3,6 +3,7 @@
// found in the LICENSE file.
#include "base/keyboard_codes.h"
#include "chrome/browser/wrench_menu_model.h"
#include "chrome/test/automation/browser_proxy.h"
#include "chrome/test/automation/tab_proxy.h"
#include "chrome/test/automation/window_proxy.h"
......@@ -69,8 +70,10 @@ void KeyboardAccessTest::TestMenuKeyboardAccess(bool alternate_key_sequence) {
ASSERT_TRUE(browser->StartTrackingPopupMenus());
// Press RIGHT to focus the app menu, then RETURN or DOWN to open it.
ASSERT_TRUE(window->SimulateOSKeyPress(base::VKEY_RIGHT, 0));
if (!WrenchMenuModel::IsEnabled()) {
// Press RIGHT to focus the app menu, then RETURN or DOWN to open it.
ASSERT_TRUE(window->SimulateOSKeyPress(base::VKEY_RIGHT, 0));
}
if (alternate_key_sequence)
ASSERT_TRUE(window->SimulateOSKeyPress(base::VKEY_DOWN, 0));
else
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment