Index: chrome/browser/global_keyboard_shortcuts_mac.h |
diff --git a/chrome/browser/global_keyboard_shortcuts_mac.h b/chrome/browser/global_keyboard_shortcuts_mac.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..45d9a69c732aee8f0594454d09f60c8f98b0fec6 |
--- /dev/null |
+++ b/chrome/browser/global_keyboard_shortcuts_mac.h |
@@ -0,0 +1,27 @@ |
+// Copyright (c) 2009 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef CHROME_BROWSER_GLOBAL_KEYBOARD_SHORTCUTS_MAC_H_ |
+#define CHROME_BROWSER_GLOBAL_KEYBOARD_SHORTCUTS_MAC_H_ |
+ |
+#include "base/basictypes.h"; |
+ |
+struct KeyboardShortcutData { |
+ bool command_key; |
+ bool shift_key; |
+ bool cntrl_key; |
+ int vkey_code; // Virtual Key code for the command. |
+ int chrome_command; // The chrome command # to execute for this shortcut. |
+}; |
+ |
+// Check if a given keycode + modifiers correspond to a given Chrome command. |
+// returns: Command number (as passed to Browser::ExecuteCommand) or -1 if there |
+// was no match. |
+int CommandForKeyboardShortcut(bool command_key, bool shift_key, bool cntrl_key, |
+ int vkey_code); |
+ |
+// For testing purposes. |
+const KeyboardShortcutData* GetKeyboardShortCutTable(size_t* num_entries); |
+ |
+#endif // #ifndef CHROME_BROWSER_GLOBAL_KEYBOARD_SHORTCUTS_MAC_H_ |