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

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

Issue 1922993002: Remove the backspace/shift+backspace navigating the page. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address review Created 4 years, 7 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
« no previous file with comments | « no previous file | chrome/browser/global_keyboard_shortcuts_mac_unittest.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/logging.h" 9 #include "base/logging.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 return keyboard_shortcuts; 96 return keyboard_shortcuts;
97 } 97 }
98 98
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},
107 {false, true, false, false, kVK_Delete, 0, IDC_FORWARD},
108 {true, true, false, false, 0, 'c', IDC_DEV_TOOLS_INSPECT}, 106 {true, true, false, false, 0, 'c', IDC_DEV_TOOLS_INSPECT},
109 }; 107 };
110 108
111 *num_entries = arraysize(keyboard_shortcuts); 109 *num_entries = arraysize(keyboard_shortcuts);
112 110
113 return keyboard_shortcuts; 111 return keyboard_shortcuts;
114 } 112 }
115 113
116 static bool MatchesEventForKeyboardShortcut( 114 static bool MatchesEventForKeyboardShortcut(
117 const KeyboardShortcutData& shortcut, 115 const KeyboardShortcutData& shortcut,
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after
290 } 288 }
291 } 289 }
292 290
293 // opt/alt modifier is set (e.g. on german layout we want '{' for opt-8). 291 // opt/alt modifier is set (e.g. on german layout we want '{' for opt-8).
294 if ([event modifierFlags] & NSAlternateKeyMask) 292 if ([event modifierFlags] & NSAlternateKeyMask)
295 return rawChar; 293 return rawChar;
296 } 294 }
297 295
298 return noModifiersChar; 296 return noModifiersChar;
299 } 297 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/global_keyboard_shortcuts_mac_unittest.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698