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

Side by Side Diff: chrome/browser/profiles/profile_manager.cc

Issue 6905044: Refactor preference syncing. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase + comments Created 9 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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 <set> 5 #include <set>
6 6
7 #include "chrome/browser/profiles/profile_manager.h" 7 #include "chrome/browser/profiles/profile_manager.h"
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/file_path.h" 10 #include "base/file_path.h"
(...skipping 481 matching lines...) Expand 10 before | Expand all | Expand 10 after
492 local_state->SetInteger(prefs::kProfilesNumCreated, ++next_directory); 492 local_state->SetInteger(prefs::kProfilesNumCreated, ++next_directory);
493 493
494 ProfileManager* profile_manager = g_browser_process->profile_manager(); 494 ProfileManager* profile_manager = g_browser_process->profile_manager();
495 // The launcher is deleted by the manager when profile creation is finished. 495 // The launcher is deleted by the manager when profile creation is finished.
496 NewProfileLauncher* launcher = new NewProfileLauncher(); 496 NewProfileLauncher* launcher = new NewProfileLauncher();
497 profile_manager->CreateProfileAsync(new_path, launcher); 497 profile_manager->CreateProfileAsync(new_path, launcher);
498 } 498 }
499 499
500 // static 500 // static
501 void ProfileManager::RegisterPrefs(PrefService* prefs) { 501 void ProfileManager::RegisterPrefs(PrefService* prefs) {
502 prefs->RegisterStringPref(prefs::kProfileLastUsed, ""); 502 prefs->RegisterStringPref(prefs::kProfileLastUsed,
503 prefs->RegisterDictionaryPref(prefs::kProfileDirectoryMap); 503 "",
504 prefs->RegisterIntegerPref(prefs::kProfilesNumCreated, 1); 504 false /* don't sync pref */);
505 prefs->RegisterDictionaryPref(prefs::kProfileDirectoryMap,
506 false /* don't sync pref */);
507 prefs->RegisterIntegerPref(prefs::kProfilesNumCreated,
508 1,
509 false /* don't sync pref */);
505 } 510 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698