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

Side by Side Diff: ios/chrome/browser/ui/key_commands_provider.mm

Issue 2965963002: [ios] Remove IDC_STOP and IDC_RELOAD
Patch Set: Rebased. Created 3 years, 5 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "ios/chrome/browser/ui/key_commands_provider.h" 5 #import "ios/chrome/browser/ui/key_commands_provider.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "components/strings/grit/components_strings.h" 8 #include "components/strings/grit/components_strings.h"
9 #import "ios/chrome/browser/ui/commands/generic_chrome_command.h" 9 #import "ios/chrome/browser/ui/commands/generic_chrome_command.h"
10 #include "ios/chrome/browser/ui/commands/ios_command_ids.h" 10 #include "ios/chrome/browser/ui/commands/ios_command_ids.h"
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after
149 modifierFlags:UIKeyModifierCommand | UIKeyModifierShift 149 modifierFlags:UIKeyModifierCommand | UIKeyModifierShift
150 title:nil 150 title:nil
151 action:^{ 151 action:^{
152 execute(IDC_FIND_PREVIOUS); 152 execute(IDC_FIND_PREVIOUS);
153 }], 153 }],
154 [UIKeyCommand cr_keyCommandWithInput:@"r" 154 [UIKeyCommand cr_keyCommandWithInput:@"r"
155 modifierFlags:UIKeyModifierCommand 155 modifierFlags:UIKeyModifierCommand
156 title:l10n_util::GetNSStringWithFixup( 156 title:l10n_util::GetNSStringWithFixup(
157 IDS_IOS_ACCNAME_RELOAD) 157 IDS_IOS_ACCNAME_RELOAD)
158 action:^{ 158 action:^{
159 execute(IDC_RELOAD); 159 [weakDispatcher reload];
160 }], 160 }],
161 ]]; 161 ]];
162 162
163 // Since cmd+left and cmd+right are valid system shortcuts when editing 163 // Since cmd+left and cmd+right are valid system shortcuts when editing
164 // text, don't register those if text is being edited. 164 // text, don't register those if text is being edited.
165 if (!editingText) { 165 if (!editingText) {
166 [keyCommands addObjectsFromArray:@[ 166 [keyCommands addObjectsFromArray:@[
167 [UIKeyCommand cr_keyCommandWithInput:UIKeyInputLeftArrow 167 [UIKeyCommand cr_keyCommandWithInput:UIKeyInputLeftArrow
168 modifierFlags:UIKeyModifierCommand 168 modifierFlags:UIKeyModifierCommand
169 title:l10n_util::GetNSStringWithFixup( 169 title:l10n_util::GetNSStringWithFixup(
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
240 [UIKeyCommand cr_keyCommandWithInput:@"]" 240 [UIKeyCommand cr_keyCommandWithInput:@"]"
241 modifierFlags:UIKeyModifierCommand 241 modifierFlags:UIKeyModifierCommand
242 title:nil 242 title:nil
243 action:^{ 243 action:^{
244 browseRight(); 244 browseRight();
245 }], 245 }],
246 [UIKeyCommand cr_keyCommandWithInput:@"." 246 [UIKeyCommand cr_keyCommandWithInput:@"."
247 modifierFlags:UIKeyModifierCommand 247 modifierFlags:UIKeyModifierCommand
248 title:nil 248 title:nil
249 action:^{ 249 action:^{
250 execute(IDC_STOP); 250 [weakDispatcher stopLoading];
251 }], 251 }],
252 [UIKeyCommand cr_keyCommandWithInput:@"?" 252 [UIKeyCommand cr_keyCommandWithInput:@"?"
253 modifierFlags:UIKeyModifierCommand 253 modifierFlags:UIKeyModifierCommand
254 title:nil 254 title:nil
255 action:^{ 255 action:^{
256 execute(IDC_HELP_PAGE_VIA_MENU); 256 execute(IDC_HELP_PAGE_VIA_MENU);
257 }], 257 }],
258 [UIKeyCommand cr_keyCommandWithInput:@"1" 258 [UIKeyCommand cr_keyCommandWithInput:@"1"
259 modifierFlags:UIKeyModifierCommand 259 modifierFlags:UIKeyModifierCommand
260 title:nil 260 title:nil
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
323 action:^{ 323 action:^{
324 [weakConsumer focusNextTab]; 324 [weakConsumer focusNextTab];
325 }], 325 }],
326 ]]; 326 ]];
327 } 327 }
328 328
329 return keyCommands; 329 return keyCommands;
330 } 330 }
331 331
332 @end 332 @end
OLDNEW
« no previous file with comments | « ios/chrome/browser/ui/commands/ios_command_ids.h ('k') | ios/chrome/browser/ui/omnibox/page_info_view_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698