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

Unified Diff: chrome/browser/autofill/personal_data_manager.cc

Issue 12340111: Introduce //components/user_prefs, use to eliminate c/b/prefs dependency in Autofill. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Pure merge of LKGR Created 7 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
Index: chrome/browser/autofill/personal_data_manager.cc
diff --git a/chrome/browser/autofill/personal_data_manager.cc b/chrome/browser/autofill/personal_data_manager.cc
index 685e82dda98338f9fca14389f60ccaf0f96e83b7..5a9334118480fe46f6413ab052f9c90f293355a0 100644
--- a/chrome/browser/autofill/personal_data_manager.cc
+++ b/chrome/browser/autofill/personal_data_manager.cc
@@ -26,6 +26,7 @@
#include "chrome/browser/autofill/validation.h"
#include "chrome/common/chrome_notification_types.h"
#include "chrome/common/pref_names.h"
+#include "components/user_prefs/user_prefs.h"
#include "content/public/browser/browser_context.h"
#include "content/public/browser/notification_source.h"
@@ -517,7 +518,7 @@ bool PersonalDataManager::IsDataLoaded() const {
}
const std::vector<AutofillProfile*>& PersonalDataManager::GetProfiles() {
- if (!PrefServiceFromBrowserContext(browser_context_)->GetBoolean(
+ if (!components::UserPrefs::Get(browser_context_)->GetBoolean(
prefs::kAutofillAuxiliaryProfilesEnabled)) {
return web_profiles();
}
@@ -664,7 +665,7 @@ void PersonalDataManager::GetCreditCardSuggestions(
}
bool PersonalDataManager::IsAutofillEnabled() const {
- return PrefServiceFromBrowserContext(browser_context_)->GetBoolean(
+ return components::UserPrefs::Get(browser_context_)->GetBoolean(
prefs::kAutofillEnabled);
}

Powered by Google App Engine
This is Rietveld 408576698