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

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

Issue 184273011: Merge 253787 "[GCM] Make sure GCM checkout logic is invoked when..." (Closed) Base URL: svn://svn.chromium.org/chrome/branches/1847/src/
Patch Set: Created 6 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
« no previous file with comments | « chrome/browser/sync/profile_sync_service.cc ('k') | google_apis/gcm/engine/mcs_client.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/sync/profile_sync_service_factory.cc
===================================================================
--- chrome/browser/sync/profile_sync_service_factory.cc (revision 255183)
+++ chrome/browser/sync/profile_sync_service_factory.cc (working copy)
@@ -95,16 +95,10 @@
SigninManagerBase* signin = SigninManagerFactory::GetForProfile(profile);
- // Automatically load the GCMProfileService if the enabled state has been
- // explicitly set.
- const base::Value* gcm_enabled_value =
- profile->GetPrefs()->GetUserPrefValue(prefs::kGCMChannelEnabled);
- bool gcm_enabled = false;
- if (gcm_enabled_value &&
- gcm_enabled_value->GetAsBoolean(&gcm_enabled) &&
- gcm_enabled) {
- gcm::GCMProfileServiceFactory::GetForProfile(profile);
- }
+ // Always create the GCMProfileService instance such that we can listen to
+ // the profile notifications and purge the GCM store when the profile is
+ // being signed out.
+ gcm::GCMProfileServiceFactory::GetForProfile(profile);
// TODO(atwilson): Change AboutSigninInternalsFactory to load on startup
// once http://crbug.com/171406 has been fixed.
« no previous file with comments | « chrome/browser/sync/profile_sync_service.cc ('k') | google_apis/gcm/engine/mcs_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698