From 0d03f958e30b7e6915b73f61cbe3ef79af2916dd Mon Sep 17 00:00:00 2001 From: "dhollowa@chromium.org" Date: Mon, 28 Jun 2010 21:31:13 +0000 Subject: AutoFill "me" card integration defaults to enabled on Mac Changes the default preference setting for Mac "me" card integration to be enabled. BUG=46695 TEST=AutoFillDialogControllerTest.AuxiliaryProfilesTrue Review URL: http://codereview.chromium.org/2800031 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@51047 0039d316-1c4b-4281-b951-d872f2087c98 --- .../autofill/autofill_dialog_controller_mac_unittest.mm | 11 ++++++----- chrome/browser/autofill/autofill_manager.cc | 2 +- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/chrome/browser/autofill/autofill_dialog_controller_mac_unittest.mm b/chrome/browser/autofill/autofill_dialog_controller_mac_unittest.mm index 356e12e..1fc4373 100644 --- a/chrome/browser/autofill/autofill_dialog_controller_mac_unittest.mm +++ b/chrome/browser/autofill/autofill_dialog_controller_mac_unittest.mm @@ -500,7 +500,8 @@ TEST_F(AutoFillDialogControllerTest, TwoCreditCardsDeleteOne) { ASSERT_EQ(observer_.credit_cards_[0], credit_card); } -TEST_F(AutoFillDialogControllerTest, AuxiliaryProfilesFalse) { +// Auxilliary profiles are enabled by default. +TEST_F(AutoFillDialogControllerTest, AuxiliaryProfilesTrue) { LoadDialog(); [controller_ save:nil]; @@ -508,13 +509,13 @@ TEST_F(AutoFillDialogControllerTest, AuxiliaryProfilesFalse) { ASSERT_TRUE(observer_.hit_); // Auxiliary profiles setting should be unchanged. - ASSERT_FALSE(helper_.profile()->GetPrefs()->GetBoolean( + ASSERT_TRUE(helper_.profile()->GetPrefs()->GetBoolean( prefs::kAutoFillAuxiliaryProfilesEnabled)); } -TEST_F(AutoFillDialogControllerTest, AuxiliaryProfilesTrue) { +TEST_F(AutoFillDialogControllerTest, AuxiliaryProfilesFalse) { helper_.profile()->GetPrefs()->SetBoolean( - prefs::kAutoFillAuxiliaryProfilesEnabled, true); + prefs::kAutoFillAuxiliaryProfilesEnabled, false); LoadDialog(); [controller_ save:nil]; @@ -522,7 +523,7 @@ TEST_F(AutoFillDialogControllerTest, AuxiliaryProfilesTrue) { ASSERT_TRUE(observer_.hit_); // Auxiliary profiles setting should be unchanged. - ASSERT_TRUE(helper_.profile()->GetPrefs()->GetBoolean( + ASSERT_FALSE(helper_.profile()->GetPrefs()->GetBoolean( prefs::kAutoFillAuxiliaryProfilesEnabled)); } diff --git a/chrome/browser/autofill/autofill_manager.cc b/chrome/browser/autofill/autofill_manager.cc index 4d489ef..2be20db 100644 --- a/chrome/browser/autofill/autofill_manager.cc +++ b/chrome/browser/autofill/autofill_manager.cc @@ -70,7 +70,7 @@ void AutoFillManager::RegisterBrowserPrefs(PrefService* prefs) { void AutoFillManager::RegisterUserPrefs(PrefService* prefs) { prefs->RegisterBooleanPref(prefs::kAutoFillInfoBarShown, false); prefs->RegisterBooleanPref(prefs::kAutoFillEnabled, true); - prefs->RegisterBooleanPref(prefs::kAutoFillAuxiliaryProfilesEnabled, false); + prefs->RegisterBooleanPref(prefs::kAutoFillAuxiliaryProfilesEnabled, true); prefs->RegisterRealPref(prefs::kAutoFillPositiveUploadRate, kAutoFillPositiveUploadRateDefaultValue); -- cgit v1.1