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

Unified Diff: chrome/browser/search_engines/template_url_service_factory.cc

Issue 14141006: [components] Switch {RefCounted}ProfileKeyedService to use BrowserContext (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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/search_engines/template_url_service_factory.cc
diff --git a/chrome/browser/search_engines/template_url_service_factory.cc b/chrome/browser/search_engines/template_url_service_factory.cc
index 561fefb2230e0cf0e6b7c0a04ca85bc83bbf6227..b379d241a35cdb2d3fa4af79a77a2179b7e6bdbe 100644
--- a/chrome/browser/search_engines/template_url_service_factory.cc
+++ b/chrome/browser/search_engines/template_url_service_factory.cc
@@ -41,8 +41,8 @@ TemplateURLServiceFactory::TemplateURLServiceFactory()
TemplateURLServiceFactory::~TemplateURLServiceFactory() {}
ProfileKeyedService* TemplateURLServiceFactory::BuildServiceInstanceFor(
- Profile* profile) const {
- return BuildInstanceFor(profile);
+ content::BrowserContext* profile) const {
+ return BuildInstanceFor(static_cast<Profile*>(profile));
}
void TemplateURLServiceFactory::RegisterUserPrefs(
@@ -96,7 +96,7 @@ bool TemplateURLServiceFactory::ServiceIsNULLWhileTesting() const {
return true;
}
-void TemplateURLServiceFactory::ProfileShutdown(Profile* profile) {
+void TemplateURLServiceFactory::ProfileShutdown(content::BrowserContext* profile) {
// We shutdown AND destroy the TemplateURLService during this pass.
// TemplateURLService schedules a task on the WebDataService from its
// destructor. Delete it first to ensure the task gets scheduled before we
@@ -105,6 +105,6 @@ void TemplateURLServiceFactory::ProfileShutdown(Profile* profile) {
ProfileKeyedServiceFactory::ProfileDestroyed(profile);
}
-void TemplateURLServiceFactory::ProfileDestroyed(Profile* profile) {
+void TemplateURLServiceFactory::ProfileDestroyed(content::BrowserContext* profile) {
// Don't double delete.
}

Powered by Google App Engine
This is Rietveld 408576698