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

Unified Diff: chrome/browser/sync/profile_sync_service_factory.cc

Issue 15517005: Remove references to Profile from browser_context_keyed_service. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase & style Created 7 years, 7 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/sync/profile_sync_service_factory.cc
diff --git a/chrome/browser/sync/profile_sync_service_factory.cc b/chrome/browser/sync/profile_sync_service_factory.cc
index 635a119448ed983c630402367e73e9e873f697d2..9a5718a8d692c03770fc3203f9ae87df6e1eff24 100644
--- a/chrome/browser/sync/profile_sync_service_factory.cc
+++ b/chrome/browser/sync/profile_sync_service_factory.cc
@@ -44,12 +44,13 @@ ProfileSyncService* ProfileSyncServiceFactory::GetForProfile(
return NULL;
return static_cast<ProfileSyncService*>(
- GetInstance()->GetServiceForProfile(profile, true));
+ GetInstance()->GetServiceForBrowserContext(profile, true));
}
ProfileSyncServiceFactory::ProfileSyncServiceFactory()
- : ProfileKeyedServiceFactory("ProfileSyncService",
- ProfileDependencyManager::GetInstance()) {
+ : BrowserContextKeyedServiceFactory(
+ "ProfileSyncService",
+ BrowserContextDependencyManager::GetInstance()) {
// The ProfileSyncService depends on various SyncableServices being around
// when it is shut down. Specify those dependencies here to build the proper
@@ -68,10 +69,10 @@ ProfileSyncServiceFactory::ProfileSyncServiceFactory()
DependsOn(BookmarkModelFactory::GetInstance());
DependsOn(AboutSigninInternalsFactory::GetInstance());
- // The following have not been converted to ProfileKeyedServices yet, and for
- // now they are explicitly destroyed after the ProfileDependencyManager is
- // told to DestroyProfileServices, so they will be around when the
- // ProfileSyncService is destroyed.
+ // The following have not been converted to BrowserContextKeyedServices yet,
+ // and for now they are explicitly destroyed after the
+ // BrowserContextDependencyManager is told to DestroyBrowserContextServices,
+ // so they will be around when the ProfileSyncService is destroyed.
// DependsOn(FaviconServiceFactory::GetInstance());
}
@@ -79,7 +80,7 @@ ProfileSyncServiceFactory::ProfileSyncServiceFactory()
ProfileSyncServiceFactory::~ProfileSyncServiceFactory() {
}
-ProfileKeyedService* ProfileSyncServiceFactory::BuildServiceInstanceFor(
+BrowserContextKeyedService* ProfileSyncServiceFactory::BuildServiceInstanceFor(
content::BrowserContext* context) const {
Profile* profile = static_cast<Profile*>(context);
@@ -113,5 +114,5 @@ ProfileKeyedService* ProfileSyncServiceFactory::BuildServiceInstanceFor(
// static
bool ProfileSyncServiceFactory::HasProfileSyncService(Profile* profile) {
- return GetInstance()->GetServiceForProfile(profile, false) != NULL;
+ return GetInstance()->GetServiceForBrowserContext(profile, false) != NULL;
}

Powered by Google App Engine
This is Rietveld 408576698