summaryrefslogtreecommitdiffstats
path: root/components
diff options
context:
space:
mode:
authorphajdan.jr@chromium.org <phajdan.jr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-26 18:09:02 +0000
committerphajdan.jr@chromium.org <phajdan.jr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-26 18:09:02 +0000
commitc7fa4367503441fefc7da332b0bddd329ceea9dd (patch)
treeb1469aab9cb635f9f00096b7f746047272474690 /components
parentaca70615b08a5d741e5a10b91c8746e74d66f897 (diff)
downloadchromium_src-c7fa4367503441fefc7da332b0bddd329ceea9dd.zip
chromium_src-c7fa4367503441fefc7da332b0bddd329ceea9dd.tar.gz
chromium_src-c7fa4367503441fefc7da332b0bddd329ceea9dd.tar.bz2
[components] Switch {RefCounted}ProfileKeyedService to use BrowserContext
instead of Profile. This will help move it out of chrome. BUG=227219 Review URL: https://codereview.chromium.org/14141006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@196777 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'components')
-rw-r--r--components/autofill/browser/autocomplete_history_manager_unittest.cc2
-rw-r--r--components/autofill/browser/autofill_manager_unittest.cc2
-rw-r--r--components/user_prefs/user_prefs.cc1
3 files changed, 3 insertions, 2 deletions
diff --git a/components/autofill/browser/autocomplete_history_manager_unittest.cc b/components/autofill/browser/autocomplete_history_manager_unittest.cc
index 8567221..7b308dc 100644
--- a/components/autofill/browser/autocomplete_history_manager_unittest.cc
+++ b/components/autofill/browser/autocomplete_history_manager_unittest.cc
@@ -62,7 +62,7 @@ MockWebDataService* MockWebDataService::current_mock_web_data_service_ = NULL;
class MockWebDataServiceWrapperCurrent : public MockWebDataServiceWrapperBase {
public:
- static ProfileKeyedService* Build(Profile* profile) {
+ static ProfileKeyedService* Build(content::BrowserContext* profile) {
return new MockWebDataServiceWrapperCurrent();
}
diff --git a/components/autofill/browser/autofill_manager_unittest.cc b/components/autofill/browser/autofill_manager_unittest.cc
index 9f53518..0c9b9ce0 100644
--- a/components/autofill/browser/autofill_manager_unittest.cc
+++ b/components/autofill/browser/autofill_manager_unittest.cc
@@ -86,7 +86,7 @@ class TestPersonalDataManager : public PersonalDataManager {
}
// Factory method for keyed service. PersonalDataManager is NULL for testing.
- static ProfileKeyedService* Build(Profile* profile) {
+ static ProfileKeyedService* Build(content::BrowserContext* profile) {
return NULL;
}
diff --git a/components/user_prefs/user_prefs.cc b/components/user_prefs/user_prefs.cc
index 96866d1..73b8ece 100644
--- a/components/user_prefs/user_prefs.cc
+++ b/components/user_prefs/user_prefs.cc
@@ -25,6 +25,7 @@ void* UserDataKey() {
// static
PrefService* UserPrefs::Get(content::BrowserContext* context) {
DCHECK(context);
+ DCHECK(context->GetUserData(UserDataKey()));
return static_cast<UserPrefs*>(
context->GetUserData(UserDataKey()))->prefs_;
}