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

Side by Side Diff: ios/chrome/browser/ui/keyboard/UIKeyCommand+Chrome.h

Issue 1469903002: Let the MainController dismiss presented modals. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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 | « ios/chrome/browser/ui/commands/ios_command_ids.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 IOS_CHROME_BROWSER_UI_KEYBOARD_UIKEYCOMMAND_CHROME_H_ 5 #ifndef IOS_CHROME_BROWSER_UI_KEYBOARD_UIKEYCOMMAND_CHROME_H_
6 #define IOS_CHROME_BROWSER_UI_KEYBOARD_UIKEYCOMMAND_CHROME_H_ 6 #define IOS_CHROME_BROWSER_UI_KEYBOARD_UIKEYCOMMAND_CHROME_H_
7 7
8 #import <Foundation/Foundation.h> 8 #import <Foundation/Foundation.h>
9 #import <UIKit/UIKit.h> 9 #import <UIKit/UIKit.h>
10 10
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 // title:@"New Tab" 50 // title:@"New Tab"
51 // action:^{ 51 // action:^{
52 // base::scoped_nsobject<Foo> strongSelf([weakSelf retain]); 52 // base::scoped_nsobject<Foo> strongSelf([weakSelf retain]);
53 // if (!strongSelf) 53 // if (!strongSelf)
54 // return; 54 // return;
55 // [strongSelf openNewTab]; 55 // [strongSelf openNewTab];
56 // }], 56 // }],
57 // ]; 57 // ];
58 // } 58 // }
59 // 59 //
60 // Or in a UIViewController: 60 // Or in a UIViewController starting in iOS 9:
61 // 61 //
62 // baz_view_controller.mm: 62 // baz_view_controller.mm:
63 // 63 //
64 // - (void)viewDidLoad { 64 // - (void)viewDidLoad {
65 // … 65 // …
66 // [self addKeyCommand:[UIKeyCommand cr_keyCommandWithInput:input 66 // [self addKeyCommand:[UIKeyCommand cr_keyCommandWithInput:input
67 // modifierFlags:modifierFlags 67 // modifierFlags:modifierFlags
68 // title:title 68 // title:title
69 // action:action]]; 69 // action:action]];
70 // … 70 // …
(...skipping 13 matching lines...) Expand all
84 + (instancetype)cr_keyCommandWithInput:(NSString*)input 84 + (instancetype)cr_keyCommandWithInput:(NSString*)input
85 modifierFlags:(UIKeyModifierFlags)modifierFlags 85 modifierFlags:(UIKeyModifierFlags)modifierFlags
86 title:(nullable NSString*)discoveryTitle 86 title:(nullable NSString*)discoveryTitle
87 action:(UIKeyCommandAction)action; 87 action:(UIKeyCommandAction)action;
88 88
89 @end 89 @end
90 90
91 NS_ASSUME_NONNULL_END 91 NS_ASSUME_NONNULL_END
92 92
93 #endif // IOS_CHROME_BROWSER_UI_KEYBOARD_UIKEYCOMMAND_CHROME_H_ 93 #endif // IOS_CHROME_BROWSER_UI_KEYBOARD_UIKEYCOMMAND_CHROME_H_
OLDNEW
« no previous file with comments | « ios/chrome/browser/ui/commands/ios_command_ids.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698