OLD | NEW |
(Empty) | |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CHROME_BROWSER_UI_COCOA_CHROME_COMMAND_DISPATCH_DELEGATE_H_ |
| 6 #define CHROME_BROWSER_UI_COCOA_CHROME_COMMAND_DISPATCH_DELEGATE_H_ |
| 7 |
| 8 #import <Cocoa/Cocoa.h> |
| 9 |
| 10 #import "ui/base/cocoa/command_dispatch_delegate.h" |
| 11 |
| 12 // Implement CommandDispatchDelegate by intercepting browser window keyboard |
| 13 // shortcuts and executing them with chrome::ExecuteCommand. |
| 14 @interface ChromeCommandDispatchDelegate : NSObject<CommandDispatchDelegate> { |
| 15 @private |
| 16 BOOL redispatchingEvent_; |
| 17 BOOL eventHandled_; |
| 18 } |
| 19 |
| 20 // Checks if |event| is a window, delayed window, or browser keyboard shortcut. |
| 21 // (See global_keyboard_shortcuts_mac.h for details). If so, execute the |
| 22 // associated command. Returns YES if the event was handled. |
| 23 - (BOOL)handleExtraKeyboardShortcut:(NSEvent*)event window:(NSWindow*)window; |
| 24 |
| 25 @end |
| 26 |
| 27 #endif // CHROME_BROWSER_UI_COCOA_CHROME_COMMAND_DISPATCH_DELEGATE_H_ |
OLD | NEW |