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

Side by Side Diff: chrome/browser/invalidation/ticl_profile_settings_provider.cc

Issue 286213003: Make GCMProfileService own GCMDriver, instead of deriving from it (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Sync Created 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/invalidation/ticl_profile_settings_provider.h" 5 #include "chrome/browser/invalidation/ticl_profile_settings_provider.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/prefs/pref_service.h" 10 #include "base/prefs/pref_service.h"
11 #include "chrome/browser/profiles/profile.h" 11 #include "chrome/browser/profiles/profile.h"
12 #include "chrome/browser/services/gcm/gcm_driver.h"
fgorski 2014/05/19 17:33:32 is that needed?
jianli 2014/05/19 18:37:20 Removed.
12 #include "chrome/browser/services/gcm/gcm_profile_service.h" 13 #include "chrome/browser/services/gcm/gcm_profile_service.h"
13 #include "chrome/common/chrome_switches.h" 14 #include "chrome/common/chrome_switches.h"
14 #include "chrome/common/pref_names.h" 15 #include "chrome/common/pref_names.h"
15 16
16 namespace invalidation { 17 namespace invalidation {
17 18
18 TiclProfileSettingsProvider::TiclProfileSettingsProvider(Profile* profile) 19 TiclProfileSettingsProvider::TiclProfileSettingsProvider(Profile* profile)
19 : profile_(profile) { 20 : profile_(profile) {
20 registrar_.Init(profile->GetPrefs()); 21 registrar_.Init(profile->GetPrefs());
21 registrar_.Add( 22 registrar_.Add(
(...skipping 26 matching lines...) Expand all
48 switches::kInvalidationUseGCMChannel)) { 49 switches::kInvalidationUseGCMChannel)) {
49 // Use GCM channel if it was enabled via a command-line switch. 50 // Use GCM channel if it was enabled via a command-line switch.
50 return true; 51 return true;
51 } 52 }
52 53
53 // By default, do not use GCM channel. 54 // By default, do not use GCM channel.
54 return false; 55 return false;
55 } 56 }
56 57
57 } // namespace invalidation 58 } // namespace invalidation
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698