Index: chrome/browser/profile_resetter/automatic_profile_resetter_factory.cc |
diff --git a/chrome/browser/profile_resetter/automatic_profile_resetter_factory.cc b/chrome/browser/profile_resetter/automatic_profile_resetter_factory.cc |
index 90971de6b9cd8473e0dbe9a335308cf7acf23547..10bd7c3fd85adb3a05ac39cc06ceb8c2214d5d1f 100644 |
--- a/chrome/browser/profile_resetter/automatic_profile_resetter_factory.cc |
+++ b/chrome/browser/profile_resetter/automatic_profile_resetter_factory.cc |
@@ -40,7 +40,9 @@ void AutomaticProfileResetterFactory::RegisterPrefs( |
AutomaticProfileResetterFactory::AutomaticProfileResetterFactory() |
: BrowserContextKeyedServiceFactory( |
"AutomaticProfileResetter", |
- BrowserContextDependencyManager::GetInstance()) {} |
+ BrowserContextDependencyManager::GetInstance()) { |
+ DependsOn(TemplateURLServiceFactory::GetInstance()); |
+} |
AutomaticProfileResetterFactory::~AutomaticProfileResetterFactory() {} |
@@ -49,7 +51,7 @@ AutomaticProfileResetterFactory::BuildServiceInstanceFor( |
content::BrowserContext* context) const { |
Profile* profile = Profile::FromBrowserContext(context); |
AutomaticProfileResetter* service = new AutomaticProfileResetter(profile); |
- service->Initialize(); |
+ service->Activate(); |
return service; |
} |
@@ -61,8 +63,8 @@ void AutomaticProfileResetterFactory::RegisterProfilePrefs( |
user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF); |
} |
-bool AutomaticProfileResetterFactory::ServiceIsCreatedWithBrowserContext() |
- const { |
+bool AutomaticProfileResetterFactory:: |
+ ServiceIsCreatedWithBrowserContext() const { |
return true; |
} |