| Index: chrome/browser/global_keyboard_shortcuts_mac_unittest.mm
|
| diff --git a/chrome/browser/global_keyboard_shortcuts_mac_unittest.mm b/chrome/browser/global_keyboard_shortcuts_mac_unittest.mm
|
| index 25b261dd2763aeda54cf7aa793de68d4561e2bb1..896d16149fe048ff3c459f55a345e09d4447e3e5 100644
|
| --- a/chrome/browser/global_keyboard_shortcuts_mac_unittest.mm
|
| +++ b/chrome/browser/global_keyboard_shortcuts_mac_unittest.mm
|
| @@ -11,6 +11,7 @@
|
| #include "base/macros.h"
|
| #include "chrome/app/chrome_command_ids.h"
|
| #include "testing/gtest/include/gtest/gtest.h"
|
| +#include "ui/base/ui_features.h"
|
|
|
| TEST(GlobalKeyboardShortcuts, ShortcutsToWindowCommand) {
|
| // Test that an invalid shortcut translates into an invalid command id.
|
| @@ -44,10 +45,17 @@ TEST(GlobalKeyboardShortcuts, ShortcutsToWindowCommand) {
|
| EXPECT_EQ(IDC_SELECT_PREVIOUS_TAB, CommandForWindowKeyboardShortcut(
|
| true, false, false, true, kVK_ANSI_8, '{'));
|
|
|
| + // On MacViews the IDC_SELECT_TAB_0 accelerator is mapped via the
|
| + // accelerator_table.cc, which supports mapping using only using keycodes.
|
| + // The only reason CommandForWindowKeyboardShortcut is necessary on MacViews
|
| + // is to handle the Cmd-'{' and Cmd-'}', and it doesn't need to handle
|
| + // IDC_SELECT_TAB_0, so this test could be omitted.
|
| +#if !BUILDFLAG(MAC_VIEWS_BROWSER)
|
| // Test that switching tabs triggers off keycodes and not characters (visible
|
| // with the Italian keyboard layout).
|
| EXPECT_EQ(IDC_SELECT_TAB_0, CommandForWindowKeyboardShortcut(
|
| true, false, false, false, kVK_ANSI_1, '&'));
|
| +#endif // !BUILDFLAG(MAC_VIEWS_BROWSER)
|
| }
|
|
|
| TEST(GlobalKeyboardShortcuts, KeypadNumberKeysMatch) {
|
|
|