Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(260)

Side by Side Diff: chrome/browser/ui/cocoa/chrome_command_dispatcher_delegate.h

Issue 1250403002: [Mac] Move UI item validation to UserInterfaceItemCommandHandler. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@commandexecute
Patch Set: Sync to new CommandDispatcher design. Add UserInterfaceItemCommandHandler. Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 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 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_UI_COCOA_CHROME_COMMAND_DISPATCHER_DELEGATE_H_ 5 #ifndef CHROME_BROWSER_UI_COCOA_CHROME_COMMAND_DISPATCHER_DELEGATE_H_
6 #define CHROME_BROWSER_UI_COCOA_CHROME_COMMAND_DISPATCHER_DELEGATE_H_ 6 #define CHROME_BROWSER_UI_COCOA_CHROME_COMMAND_DISPATCHER_DELEGATE_H_
7 7
8 #import <Cocoa/Cocoa.h> 8 #import <Cocoa/Cocoa.h>
9 9
10 #import "ui/base/cocoa/command_dispatcher.h" 10 #import "ui/base/cocoa/command_dispatcher.h"
11 11
12 // Implement CommandDispatcherDelegate by intercepting browser window keyboard 12 // Implement CommandDispatcherDelegate by intercepting browser window keyboard
13 // shortcuts and executing them with chrome::ExecuteCommand. 13 // shortcuts and executing them with chrome::ExecuteCommand.
tapted 2015/08/27 07:24:42 update comment?
jackhou1 2015/09/03 01:12:49 Done.
14 @interface ChromeCommandDispatcherDelegate : NSObject<CommandDispatcherDelegate> 14 @interface ChromeCommandDispatcherDelegate
15 : NSObject<CommandDispatcherDelegate, UserInterfaceItemCommandHandler>
15 16
16 // Checks if |event| is a keyboard shortcut listed in 17 // Checks if |event| is a keyboard shortcut listed in
17 // global_keyboard_shortcuts_mac.h. If so, execute the associated command. 18 // global_keyboard_shortcuts_mac.h. If so, execute the associated command.
18 // Returns YES if the event was handled. 19 // Returns YES if the event was handled.
19 - (BOOL)handleExtraKeyboardShortcut:(NSEvent*)event window:(NSWindow*)window; 20 - (BOOL)handleExtraKeyboardShortcut:(NSEvent*)event window:(NSWindow*)window;
20 21
21 @end 22 @end
22 23
23 #endif // CHROME_BROWSER_UI_COCOA_CHROME_COMMAND_DISPATCHER_DELEGATE_H_ 24 #endif // CHROME_BROWSER_UI_COCOA_CHROME_COMMAND_DISPATCHER_DELEGATE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698