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

Side by Side Diff: ios/chrome/browser/payments/payment_method_selection_coordinator.h

Issue 2621453002: Selected shipping option in payment summary view + shipping option selection view (Closed)
Patch Set: Addressed comments by lpromero@ and jdonnelley@ Created 3 years, 11 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 #ifndef IOS_CHROME_BROWSER_PAYMENTS_PAYMENT_METHOD_SELECTION_COORDINATOR_H_ 5 #ifndef IOS_CHROME_BROWSER_PAYMENTS_PAYMENT_METHOD_SELECTION_COORDINATOR_H_
6 #define IOS_CHROME_BROWSER_PAYMENTS_PAYMENT_METHOD_SELECTION_COORDINATOR_H_ 6 #define IOS_CHROME_BROWSER_PAYMENTS_PAYMENT_METHOD_SELECTION_COORDINATOR_H_
7 7
8 #import <UIKit/UIKit.h> 8 #import <UIKit/UIKit.h>
9 #include <vector> 9 #include <vector>
10 10
11 #import "ios/chrome/browser/chrome_coordinator.h" 11 #import "ios/chrome/browser/chrome_coordinator.h"
12 #import "ios/chrome/browser/payments/payment_method_selection_view_controller.h" 12 #import "ios/chrome/browser/payments/payment_method_selection_view_controller.h"
13 13
14 namespace autofill { 14 namespace autofill {
15 class CreditCard; 15 class CreditCard;
16 } 16 }
17 17
18 @class PaymentMethodSelectionCoordinator; 18 @class PaymentMethodSelectionCoordinator;
19 19
20 @protocol PaymentMethodSelectionCoordinatorDelegate<NSObject> 20 @protocol PaymentMethodSelectionCoordinatorDelegate<NSObject>
21 21
22 // Notifies the delegate that the user has selected a payment method.
22 - (void)paymentMethodSelectionCoordinator: 23 - (void)paymentMethodSelectionCoordinator:
23 (PaymentMethodSelectionCoordinator*)coordinator 24 (PaymentMethodSelectionCoordinator*)coordinator
24 selectedPaymentMethod:(autofill::CreditCard*)paymentMethod; 25 selectedPaymentMethod:(autofill::CreditCard*)paymentMethod;
26
27 // Notifies the delegate that the user has chosen to return to the previous
28 // screen without making a selection.
25 - (void)paymentMethodSelectionCoordinatorDidReturn: 29 - (void)paymentMethodSelectionCoordinatorDidReturn:
26 (PaymentMethodSelectionCoordinator*)coordinator; 30 (PaymentMethodSelectionCoordinator*)coordinator;
27 31
28 @end 32 @end
29 33
30 // Coordinator responsible for creating and presenting the payment method 34 // Coordinator responsible for creating and presenting the payment method
31 // selection view controller. This view controller will be presented by the view 35 // selection view controller. This view controller will be presented by the view
32 // controller provided in the initializer. 36 // controller provided in the initializer.
33 @interface PaymentMethodSelectionCoordinator 37 @interface PaymentMethodSelectionCoordinator
34 : ChromeCoordinator<PaymentMethodSelectionViewControllerDelegate> 38 : ChromeCoordinator<PaymentMethodSelectionViewControllerDelegate>
35 39
36 // The payment methods available to fulfill the payment request. 40 // The payment methods available to fulfill the payment request.
37 @property(nonatomic, assign) std::vector<autofill::CreditCard*> paymentMethods; 41 @property(nonatomic, assign) std::vector<autofill::CreditCard*> paymentMethods;
38 42
39 // The payment method selected by the user, if any. 43 // The payment method selected by the user, if any.
40 @property(nonatomic, assign) autofill::CreditCard* selectedPaymentMethod; 44 @property(nonatomic, assign) autofill::CreditCard* selectedPaymentMethod;
41 45
42 // The delegate to be notified when the user selects a payment method or returns 46 // The delegate to be notified when the user selects a payment method or returns
43 // without selecting a payment method. 47 // without selecting a payment method.
44 @property(nonatomic, weak) id<PaymentMethodSelectionCoordinatorDelegate> 48 @property(nonatomic, weak) id<PaymentMethodSelectionCoordinatorDelegate>
45 delegate; 49 delegate;
46 50
47 @end 51 @end
48 52
49 #endif // IOS_CHROME_BROWSER_PAYMENTS_PAYMENT_METHOD_SELECTION_COORDINATOR_H_ 53 #endif // IOS_CHROME_BROWSER_PAYMENTS_PAYMENT_METHOD_SELECTION_COORDINATOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698