summaryrefslogtreecommitdiffstats
path: root/chrome/browser/autofill/autofill_dialog_mac.mm
diff options
context:
space:
mode:
authorjhawkins@chromium.org <jhawkins@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-03-19 20:06:51 +0000
committerjhawkins@chromium.org <jhawkins@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-03-19 20:06:51 +0000
commite08b6c407b50b8d003d1c9d38eda16d9c0010f18 (patch)
tree629fac1acaa3f691023fc27d7eb67d858c0e215e /chrome/browser/autofill/autofill_dialog_mac.mm
parent10d0b23d89dd21d2ca219c19c5d9bd93901f80d4 (diff)
downloadchromium_src-e08b6c407b50b8d003d1c9d38eda16d9c0010f18.zip
chromium_src-e08b6c407b50b8d003d1c9d38eda16d9c0010f18.tar.gz
chromium_src-e08b6c407b50b8d003d1c9d38eda16d9c0010f18.tar.bz2
AutoFill: Set the kAutoFillInfoBarShown pref to true if the user opens the AutoFill dialog. If the user has opened the dialog, AutoFill is implicitly enabled.
BUG=38538 TEST=none Review URL: http://codereview.chromium.org/1077003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42139 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/autofill/autofill_dialog_mac.mm')
-rw-r--r--chrome/browser/autofill/autofill_dialog_mac.mm7
1 files changed, 7 insertions, 0 deletions
diff --git a/chrome/browser/autofill/autofill_dialog_mac.mm b/chrome/browser/autofill/autofill_dialog_mac.mm
index d23236b..c011822 100644
--- a/chrome/browser/autofill/autofill_dialog_mac.mm
+++ b/chrome/browser/autofill/autofill_dialog_mac.mm
@@ -4,7 +4,9 @@
#import "chrome/browser/autofill/autofill_dialog_controller_mac.h"
#include "chrome/browser/autofill/autofill_dialog.h"
+#include "chrome/browser/pref_service.h"
#include "chrome/browser/profile.h"
+#include "chrome/common/pref_names.h"
// Mac implementation of |ShowAutoFillDialog| interface defined in
// |chrome/browser/autofill/autofill_dialog.h|.
@@ -12,6 +14,11 @@ void ShowAutoFillDialog(AutoFillDialogObserver* observer,
const std::vector<AutoFillProfile*>& profiles,
const std::vector<CreditCard*>& credit_cards,
Profile *profile) {
+ // It's possible we haven't shown the InfoBar yet, but if the user is in the
+ // AutoFill dialog, she doesn't need to be asked to enable or disable
+ // AutoFill.
+ profile->GetPrefs()->SetBoolean(prefs::kAutoFillInfoBarShown, true);
+
[AutoFillDialogController
showAutoFillDialogWithObserver:observer
autoFillProfiles:profiles