| Index: chrome/browser/ui/autofill/chrome_autofill_client.cc
|
| diff --git a/chrome/browser/ui/autofill/chrome_autofill_client.cc b/chrome/browser/ui/autofill/chrome_autofill_client.cc
|
| index 393637191d77aac6ef469f0f09ffbaeb5cf8d03a..f8b43d34ea83f4245a9d78c6a930d727d373b9fe 100644
|
| --- a/chrome/browser/ui/autofill/chrome_autofill_client.cc
|
| +++ b/chrome/browser/ui/autofill/chrome_autofill_client.cc
|
| @@ -57,6 +57,7 @@ ChromeAutofillClient::ChromeAutofillClient(content::WebContents* web_contents)
|
| user_prefs::UserPrefs::Get(web_contents->GetBrowserContext()),
|
| Profile::FromBrowserContext(web_contents->GetBrowserContext())
|
| ->IsOffTheRecord()),
|
| + save_card_bubble_controller_(web_contents),
|
| last_rfh_to_rac_(nullptr) {
|
| DCHECK(web_contents);
|
|
|
| @@ -153,9 +154,28 @@ void ChromeAutofillClient::OnUnmaskVerificationResult(GetRealPanResult result) {
|
|
|
| void ChromeAutofillClient::ConfirmSaveCreditCard(
|
| const base::Closure& save_card_callback) {
|
| +// TODO(bondd): Implement save card bubble for OS_MACOSX.
|
| +#if defined(OS_CHROMEOS) || defined(OS_LINUX) || defined(OS_WIN)
|
| + Browser* browser = chrome::FindBrowserWithWebContents(web_contents());
|
| + if (browser)
|
| + save_card_bubble_controller_.ShowBubble(save_card_callback);
|
| +#else
|
| AutofillCCInfoBarDelegate::Create(
|
| InfoBarService::FromWebContents(web_contents()), this,
|
| save_card_callback);
|
| +#endif
|
| +}
|
| +
|
| +void ChromeAutofillClient::ShowSaveCreditCardBubble() {
|
| + save_card_bubble_controller_.ReshowBubble();
|
| +}
|
| +
|
| +bool ChromeAutofillClient::WantSaveCreditCardIconVisible() {
|
| + return save_card_bubble_controller_.WantIconVisible();
|
| +}
|
| +
|
| +bool ChromeAutofillClient::WantSaveCreditCardIconToggled() {
|
| + return save_card_bubble_controller_.WantIconToggled();
|
| }
|
|
|
| bool ChromeAutofillClient::HasCreditCardScanFeature() {
|
|
|