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

Side by Side Diff: ios/chrome/browser/ui/commands/show_signin_command.h

Issue 2253113002: Add signin_metrics::AccessPoint to ShowSigninCommand. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 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 | ios/chrome/browser/ui/commands/show_signin_command.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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_COMMANDS_SHOW_SIGNIN_COMMAND_H_ 5 #ifndef IOS_CHROME_BROWSER_UI_COMMANDS_SHOW_SIGNIN_COMMAND_H_
6 #define IOS_CHROME_BROWSER_UI_COMMANDS_SHOW_SIGNIN_COMMAND_H_ 6 #define IOS_CHROME_BROWSER_UI_COMMANDS_SHOW_SIGNIN_COMMAND_H_
7 7
8 #import <Foundation/Foundation.h> 8 #import <Foundation/Foundation.h>
9 9
10 #include "components/signin/core/browser/signin_metrics.h"
10 #include "ios/chrome/browser/signin/constants.h" 11 #include "ios/chrome/browser/signin/constants.h"
11 #include "ios/chrome/browser/ui/commands/generic_chrome_command.h" 12 #include "ios/chrome/browser/ui/commands/generic_chrome_command.h"
12 13
13 typedef void (^ShowSigninCommandCompletionCallback)(BOOL succeeded); 14 typedef void (^ShowSigninCommandCompletionCallback)(BOOL succeeded);
14 15
15 enum AuthenticationOperation { 16 enum AuthenticationOperation {
16 // Operation to cancel the current authentication operation and dismiss any 17 // Operation to cancel the current authentication operation and dismiss any
17 // UI presented by this operation. 18 // UI presented by this operation.
18 AUTHENTICATION_OPERATION_DISMISS, 19 AUTHENTICATION_OPERATION_DISMISS,
19 20
(...skipping 16 matching lines...) Expand all
36 // SigninInteractionController and invoke a possibly-nil callback when finished. 37 // SigninInteractionController and invoke a possibly-nil callback when finished.
37 - (instancetype)initWithOperation:(AuthenticationOperation)operation 38 - (instancetype)initWithOperation:(AuthenticationOperation)operation
38 signInSource:(SignInSource)signInSource 39 signInSource:(SignInSource)signInSource
39 callback:(ShowSigninCommandCompletionCallback)callback 40 callback:(ShowSigninCommandCompletionCallback)callback
40 NS_DESIGNATED_INITIALIZER; 41 NS_DESIGNATED_INITIALIZER;
41 42
42 // Initializes a ShowSigninCommand with a nil callback. 43 // Initializes a ShowSigninCommand with a nil callback.
43 - (instancetype)initWithOperation:(AuthenticationOperation)operation 44 - (instancetype)initWithOperation:(AuthenticationOperation)operation
44 signInSource:(SignInSource)signInSource; 45 signInSource:(SignInSource)signInSource;
45 46
47 // Initializes a command to perform the specified operation with a
48 // SigninInteractionController and invoke a possibly-nil callback when finished.
49 - (instancetype)initWithOperation:(AuthenticationOperation)operation
50 signInAccessPoint:(signin_metrics::AccessPoint)signInAccessPoint
51 callback:(ShowSigninCommandCompletionCallback)callback;
52
53 // Initializes a ShowSigninCommand with a nil callback.
54 - (instancetype)initWithOperation:(AuthenticationOperation)operation
55 signInAccessPoint:
56 (signin_metrics::AccessPoint)signInAccessPoint;
57
46 // The callback to be invoked after the operation is complete. 58 // The callback to be invoked after the operation is complete.
47 @property(nonatomic, readonly) ShowSigninCommandCompletionCallback callback; 59 @property(nonatomic, readonly) ShowSigninCommandCompletionCallback callback;
48 60
49 // The operation to perform during the sign-in flow. 61 // The operation to perform during the sign-in flow.
50 @property(nonatomic, readonly) AuthenticationOperation operation; 62 @property(nonatomic, readonly) AuthenticationOperation operation;
51 63
52 // The source of this authentication operation. 64 // The source of this authentication operation.
53 @property(nonatomic, readonly) SignInSource signInSource; 65 @property(nonatomic, readonly) SignInSource signInSource;
54 66
67 // The access point of this authentication operation.
68 @property(nonatomic, readonly) signin_metrics::AccessPoint signInAccessPoint;
69
55 @end 70 @end
56 71
57 #endif // IOS_CHROME_BROWSER_UI_COMMANDS_SHOW_SIGNIN_COMMAND_H_ 72 #endif // IOS_CHROME_BROWSER_UI_COMMANDS_SHOW_SIGNIN_COMMAND_H_
OLDNEW
« no previous file with comments | « no previous file | ios/chrome/browser/ui/commands/show_signin_command.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698