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

Side by Side Diff: chrome/browser/global_keyboard_shortcuts_mac.mm

Issue 1428423002: Remove setVoiceSearchSupported part of EmbeddedSearch SearchBox API. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: mac fix Created 5 years, 1 month 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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #include "chrome/browser/global_keyboard_shortcuts_mac.h" 5 #include "chrome/browser/global_keyboard_shortcuts_mac.h"
6 6
7 #import <AppKit/AppKit.h> 7 #import <AppKit/AppKit.h>
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 const KeyboardShortcutData* GetBrowserKeyboardShortcutTable( 99 const KeyboardShortcutData* GetBrowserKeyboardShortcutTable(
100 size_t* num_entries) { 100 size_t* num_entries) {
101 static const KeyboardShortcutData keyboard_shortcuts[] = { 101 static const KeyboardShortcutData keyboard_shortcuts[] = {
102 //cmd shift cntrl option 102 //cmd shift cntrl option
103 //--- ----- ----- ------ 103 //--- ----- ----- ------
104 {true, false, false, false, kVK_LeftArrow, 0, IDC_BACK}, 104 {true, false, false, false, kVK_LeftArrow, 0, IDC_BACK},
105 {true, false, false, false, kVK_RightArrow, 0, IDC_FORWARD}, 105 {true, false, false, false, kVK_RightArrow, 0, IDC_FORWARD},
106 {false, false, false, false, kVK_Delete, 0, IDC_BACK}, 106 {false, false, false, false, kVK_Delete, 0, IDC_BACK},
107 {false, true, false, false, kVK_Delete, 0, IDC_FORWARD}, 107 {false, true, false, false, kVK_Delete, 0, IDC_FORWARD},
108 {true, true, false, false, 0, 'c', IDC_DEV_TOOLS_INSPECT}, 108 {true, true, false, false, 0, 'c', IDC_DEV_TOOLS_INSPECT},
109 {true, true, false, false, kVK_ANSI_Period, 0,
110 IDC_TOGGLE_SPEECH_INPUT},
111 }; 109 };
112 110
113 *num_entries = arraysize(keyboard_shortcuts); 111 *num_entries = arraysize(keyboard_shortcuts);
114 112
115 return keyboard_shortcuts; 113 return keyboard_shortcuts;
116 } 114 }
117 115
118 static bool MatchesEventForKeyboardShortcut( 116 static bool MatchesEventForKeyboardShortcut(
119 const KeyboardShortcutData& shortcut, 117 const KeyboardShortcutData& shortcut,
120 bool command_key, bool shift_key, bool cntrl_key, bool opt_key, 118 bool command_key, bool shift_key, bool cntrl_key, bool opt_key,
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
292 } 290 }
293 } 291 }
294 292
295 // opt/alt modifier is set (e.g. on german layout we want '{' for opt-8). 293 // opt/alt modifier is set (e.g. on german layout we want '{' for opt-8).
296 if ([event modifierFlags] & NSAlternateKeyMask) 294 if ([event modifierFlags] & NSAlternateKeyMask)
297 return rawChar; 295 return rawChar;
298 } 296 }
299 297
300 return noModifiersChar; 298 return noModifiersChar;
301 } 299 }
OLDNEW
« no previous file with comments | « chrome/app/theme/theme_resources.grd ('k') | chrome/browser/resources/chromeos/keyboard_overlay_data.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698