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

Side by Side Diff: chrome/browser/profiles/chrome_version_service.h

Issue 18199003: Allow Chrome OS login profile to have different default pref values (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased. Created 7 years, 5 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #ifndef CHROME_BROWSER_PROFILES_CHROME_VERSION_SERVICE_H_ 5 #ifndef CHROME_BROWSER_PROFILES_CHROME_VERSION_SERVICE_H_
6 #define CHROME_BROWSER_PROFILES_CHROME_VERSION_SERVICE_H_ 6 #define CHROME_BROWSER_PROFILES_CHROME_VERSION_SERVICE_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
11 11
12 class PrefService; 12 class PrefService;
13 13
14 namespace user_prefs { 14 namespace user_prefs {
15 class PrefRegistrySyncable; 15 class PrefRegistrySyncable;
16 } 16 }
17 17
18 // This service manages a pref which is used to determine the version of 18 // This service manages a pref which is used to determine the version of
19 // Chrome by which the profile was created. 19 // Chrome by which the profile was created.
20 class ChromeVersionService { 20 class ChromeVersionService {
21 public: 21 public:
22 // Register the user pref we use. 22 // Register the user pref we use.
23 static void RegisterUserPrefs(user_prefs::PrefRegistrySyncable* registry); 23 static void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry);
24 24
25 // Sets the version string in the pref for the current profile. 25 // Sets the version string in the pref for the current profile.
26 static void SetVersion(PrefService* prefs, const std::string& version); 26 static void SetVersion(PrefService* prefs, const std::string& version);
27 27
28 // Returns the version of Chrome which created the profile. 28 // Returns the version of Chrome which created the profile.
29 static std::string GetVersion(PrefService* prefs); 29 static std::string GetVersion(PrefService* prefs);
30 30
31 // Handles setting the profile.created_by_version Pref 31 // Handles setting the profile.created_by_version Pref
32 static void OnProfileLoaded(PrefService* prefs, bool is_new_profile); 32 static void OnProfileLoaded(PrefService* prefs, bool is_new_profile);
33 33
34 private: 34 private:
35 DISALLOW_IMPLICIT_CONSTRUCTORS(ChromeVersionService); 35 DISALLOW_IMPLICIT_CONSTRUCTORS(ChromeVersionService);
36 }; 36 };
37 37
38 #endif // CHROME_BROWSER_PROFILES_CHROME_VERSION_SERVICE_H_ 38 #endif // CHROME_BROWSER_PROFILES_CHROME_VERSION_SERVICE_H_
OLDNEW
« no previous file with comments | « chrome/browser/printing/print_dialog_cloud.cc ('k') | chrome/browser/profiles/chrome_version_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698