OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #import "chrome/browser/ui/cocoa/chrome_event_processing_window.h" | 5 #import "chrome/browser/ui/cocoa/chrome_event_processing_window.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "chrome/browser/global_keyboard_shortcuts_mac.h" |
8 #import "chrome/browser/ui/cocoa/browser_command_executor.h" | 9 #import "chrome/browser/ui/cocoa/browser_command_executor.h" |
9 #import "chrome/browser/ui/cocoa/browser_window_controller_private.h" | 10 #import "chrome/browser/ui/cocoa/browser_window_controller_private.h" |
10 #import "chrome/browser/ui/cocoa/tabs/tab_strip_controller.h" | 11 #import "chrome/browser/ui/cocoa/tabs/tab_strip_controller.h" |
11 #include "chrome/browser/global_keyboard_shortcuts_mac.h" | |
12 #import "content/public/browser/render_widget_host_view_mac_base.h" | 12 #import "content/public/browser/render_widget_host_view_mac_base.h" |
13 | 13 |
14 typedef int (*KeyToCommandMapper)(bool, bool, bool, bool, int, unichar); | 14 typedef int (*KeyToCommandMapper)(bool, bool, bool, bool, int, unichar); |
15 | 15 |
16 @interface ChromeEventProcessingWindow () | 16 @interface ChromeEventProcessingWindow () |
17 // Duplicate the given key event, but changing the associated window. | 17 // Duplicate the given key event, but changing the associated window. |
18 - (NSEvent*)keyEventForWindow:(NSWindow*)window fromKeyEvent:(NSEvent*)event; | 18 - (NSEvent*)keyEventForWindow:(NSWindow*)window fromKeyEvent:(NSEvent*)event; |
19 @end | 19 @end |
20 | 20 |
21 @implementation ChromeEventProcessingWindow | 21 @implementation ChromeEventProcessingWindow |
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
171 timestamp:[event timestamp] | 171 timestamp:[event timestamp] |
172 windowNumber:[window windowNumber] | 172 windowNumber:[window windowNumber] |
173 context:nil | 173 context:nil |
174 characters:eventCharacters | 174 characters:eventCharacters |
175 charactersIgnoringModifiers:eventUnmodCharacters | 175 charactersIgnoringModifiers:eventUnmodCharacters |
176 isARepeat:eventIsARepeat | 176 isARepeat:eventIsARepeat |
177 keyCode:[event keyCode]]; | 177 keyCode:[event keyCode]]; |
178 } | 178 } |
179 | 179 |
180 @end // ChromeEventProcessingWindow | 180 @end // ChromeEventProcessingWindow |
OLD | NEW |