| OLD | NEW |
| 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 COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_CLIENT_H_ | 5 #ifndef COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_CLIENT_H_ |
| 6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_CLIENT_H_ | 6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_CLIENT_H_ |
| 7 | 7 |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/callback_forward.h" | 10 #include "base/callback_forward.h" |
| (...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 115 // information to proceed. | 115 // information to proceed. |
| 116 virtual void ShowUnmaskPrompt(const CreditCard& card, | 116 virtual void ShowUnmaskPrompt(const CreditCard& card, |
| 117 base::WeakPtr<CardUnmaskDelegate> delegate) = 0; | 117 base::WeakPtr<CardUnmaskDelegate> delegate) = 0; |
| 118 virtual void OnUnmaskVerificationResult(GetRealPanResult result) = 0; | 118 virtual void OnUnmaskVerificationResult(GetRealPanResult result) = 0; |
| 119 | 119 |
| 120 // Run |save_card_callback| if the credit card should be imported as personal | 120 // Run |save_card_callback| if the credit card should be imported as personal |
| 121 // data. |metric_logger| can be used to log user actions. | 121 // data. |metric_logger| can be used to log user actions. |
| 122 virtual void ConfirmSaveCreditCard( | 122 virtual void ConfirmSaveCreditCard( |
| 123 const base::Closure& save_card_callback) = 0; | 123 const base::Closure& save_card_callback) = 0; |
| 124 | 124 |
| 125 // Causes the "Save credit card?" bubble to be shown. |
| 126 virtual void ShowSaveCreditCardBubble() = 0; |
| 127 |
| 128 // Returns true if "Save credit card?" Omnibox icon should be visible. |
| 129 virtual bool WantSaveCreditCardIconVisible() = 0; |
| 130 |
| 131 // Returns true if icon should be in its "toggled on" state. |
| 132 virtual bool WantSaveCreditCardIconToggled() = 0; |
| 133 |
| 125 // Returns true if both the platform and the device support scanning credit | 134 // Returns true if both the platform and the device support scanning credit |
| 126 // cards. Should be called before ScanCreditCard(). | 135 // cards. Should be called before ScanCreditCard(). |
| 127 virtual bool HasCreditCardScanFeature() = 0; | 136 virtual bool HasCreditCardScanFeature() = 0; |
| 128 | 137 |
| 129 // Shows the user interface for scanning a credit card. Invokes the |callback| | 138 // Shows the user interface for scanning a credit card. Invokes the |callback| |
| 130 // when a credit card is scanned successfully. Should be called only if | 139 // when a credit card is scanned successfully. Should be called only if |
| 131 // HasCreditCardScanFeature() returns true. | 140 // HasCreditCardScanFeature() returns true. |
| 132 virtual void ScanCreditCard(const CreditCardScanCallback& callback) = 0; | 141 virtual void ScanCreditCard(const CreditCardScanCallback& callback) = 0; |
| 133 | 142 |
| 134 // Causes the dialog for request autocomplete feature to be shown. | 143 // Causes the dialog for request autocomplete feature to be shown. |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 171 // Informs the client that a user gesture has been observed. | 180 // Informs the client that a user gesture has been observed. |
| 172 virtual void OnFirstUserGestureObserved() = 0; | 181 virtual void OnFirstUserGestureObserved() = 0; |
| 173 | 182 |
| 174 // If the context is secure. | 183 // If the context is secure. |
| 175 virtual bool IsContextSecure(const GURL& form_origin) = 0; | 184 virtual bool IsContextSecure(const GURL& form_origin) = 0; |
| 176 }; | 185 }; |
| 177 | 186 |
| 178 } // namespace autofill | 187 } // namespace autofill |
| 179 | 188 |
| 180 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_CLIENT_H_ | 189 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_CLIENT_H_ |
| OLD | NEW |