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

Unified Diff: chrome/browser/ui/autofill/chrome_autofill_client.cc

Issue 1761073005: Enable the save card bubble on Mac without a flag. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | components/autofill/core/common/autofill_switches.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 3b8ec54b2b139c17be2eddc36c875b5bc3502f27..cd0b09612f6a4d017b45276186c79819dcdb8836 100644
--- a/chrome/browser/ui/autofill/chrome_autofill_client.cc
+++ b/chrome/browser/ui/autofill/chrome_autofill_client.cc
@@ -65,21 +65,6 @@ DEFINE_WEB_CONTENTS_USER_DATA_KEY(autofill::ChromeAutofillClient);
namespace autofill {
-namespace {
-
-#if !defined(OS_ANDROID)
-bool IsSaveCardBubbleEnabled() {
-#if defined(OS_MACOSX)
- return base::CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kEnableSaveCardBubble);
-#else
- return true;
-#endif
-}
-#endif // !defined(OS_ANDROID)
-
-} // namespace
-
ChromeAutofillClient::ChromeAutofillClient(content::WebContents* web_contents)
: content::WebContentsObserver(web_contents),
unmask_controller_(
@@ -197,18 +182,12 @@ void ChromeAutofillClient::ConfirmSaveCreditCardLocally(
false, card, scoped_ptr<base::DictionaryValue>(nullptr),
callback))));
#else
- if (IsSaveCardBubbleEnabled()) {
- // Do lazy initialization of SaveCardBubbleControllerImpl.
- autofill::SaveCardBubbleControllerImpl::CreateForWebContents(
- web_contents());
- autofill::SaveCardBubbleControllerImpl* controller =
- autofill::SaveCardBubbleControllerImpl::FromWebContents(web_contents());
- controller->ShowBubbleForLocalSave(card, callback);
- return;
- }
-
- AutofillCCInfoBarDelegate::CreateForLocalSave(
Evan Stade 2016/03/07 22:42:03 do you still need this fn for something? Do you ne
Justin Donnelly 2016/03/07 23:14:41 Hmm, good point. we don't need CreateForLocalSave
- InfoBarService::FromWebContents(web_contents()), callback);
+ // Do lazy initialization of SaveCardBubbleControllerImpl.
+ autofill::SaveCardBubbleControllerImpl::CreateForWebContents(
+ web_contents());
+ autofill::SaveCardBubbleControllerImpl* controller =
+ autofill::SaveCardBubbleControllerImpl::FromWebContents(web_contents());
+ controller->ShowBubbleForLocalSave(card, callback);
#endif
}
« no previous file with comments | « no previous file | components/autofill/core/common/autofill_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698