Chromium Code Reviews| Index: chrome/browser/ui/views/payments/credit_card_editor_view_controller.h |
| diff --git a/chrome/browser/ui/views/payments/credit_card_editor_view_controller.h b/chrome/browser/ui/views/payments/credit_card_editor_view_controller.h |
| index c13e8f7a6000940311b250c3f85c510cf4794744..86116bf95bf0277ebae8b6eda261068b79cecd17 100644 |
| --- a/chrome/browser/ui/views/payments/credit_card_editor_view_controller.h |
| +++ b/chrome/browser/ui/views/payments/credit_card_editor_view_controller.h |
| @@ -5,6 +5,8 @@ |
| #ifndef CHROME_BROWSER_UI_VIEWS_PAYMENTS_CREDIT_CARD_EDITOR_VIEW_CONTROLLER_H_ |
| #define CHROME_BROWSER_UI_VIEWS_PAYMENTS_CREDIT_CARD_EDITOR_VIEW_CONTROLLER_H_ |
| +#include <set> |
| + |
| #include "base/macros.h" |
| #include "chrome/browser/ui/views/payments/editor_view_controller.h" |
| #include "chrome/browser/ui/views/payments/validation_delegate.h" |
| @@ -35,8 +37,14 @@ class CreditCardEditorViewController : public EditorViewController { |
| private: |
| class CreditCardValidationDelegate : public ValidationDelegate { |
| public: |
| - CreditCardValidationDelegate(const EditorField& field, |
| - EditorViewController* controller); |
| + // Used to validate |field| type. A reference to the |controller| should |
| + // outlive this delegate, and a list of |supported_card_networks| can be |
| + // passed in if it's thought to be used to validate |field| (the data will |
|
anthonyvd
2017/02/23 16:42:27
nit: not sure what "if it's thought to be used to
Mathieu
2017/02/23 16:48:31
Done.
|
| + // be copied to the delegate). |
| + CreditCardValidationDelegate( |
| + const EditorField& field, |
| + EditorViewController* controller, |
| + const std::vector<std::string>& supported_card_networks); |
| ~CreditCardValidationDelegate() override; |
| // ValidationDelegate: |
| @@ -50,6 +58,8 @@ class CreditCardEditorViewController : public EditorViewController { |
| EditorField field_; |
| // Outlives this class. |
| EditorViewController* controller_; |
| + // The list of supported basic card networks. |
| + std::set<std::string> supported_card_networks_; |
| DISALLOW_COPY_AND_ASSIGN(CreditCardValidationDelegate); |
| }; |