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

Side by Side Diff: chrome/browser/net/http_server_properties_manager.cc

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 #include "chrome/browser/net/http_server_properties_manager.h" 5 #include "chrome/browser/net/http_server_properties_manager.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/metrics/histogram.h" 8 #include "base/metrics/histogram.h"
9 #include "base/prefs/pref_service.h" 9 #include "base/prefs/pref_service.h"
10 #include "base/stl_util.h" 10 #include "base/stl_util.h"
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
85 85
86 void HttpServerPropertiesManager::ShutdownOnUIThread() { 86 void HttpServerPropertiesManager::ShutdownOnUIThread() {
87 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 87 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
88 // Cancel any pending updates, and stop listening for pref change updates. 88 // Cancel any pending updates, and stop listening for pref change updates.
89 ui_cache_update_timer_->Stop(); 89 ui_cache_update_timer_->Stop();
90 ui_weak_ptr_factory_.reset(); 90 ui_weak_ptr_factory_.reset();
91 pref_change_registrar_.RemoveAll(); 91 pref_change_registrar_.RemoveAll();
92 } 92 }
93 93
94 // static 94 // static
95 void HttpServerPropertiesManager::RegisterUserPrefs( 95 void HttpServerPropertiesManager::RegisterProfilePrefs(
96 user_prefs::PrefRegistrySyncable* prefs) { 96 user_prefs::PrefRegistrySyncable* prefs) {
97 prefs->RegisterDictionaryPref( 97 prefs->RegisterDictionaryPref(
98 prefs::kHttpServerProperties, 98 prefs::kHttpServerProperties,
99 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF); 99 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF);
100 } 100 }
101 101
102 // static 102 // static
103 void HttpServerPropertiesManager::SetVersion( 103 void HttpServerPropertiesManager::SetVersion(
104 base::DictionaryValue* http_server_properties_dict, 104 base::DictionaryValue* http_server_properties_dict,
105 int version_number) { 105 int version_number) {
(...skipping 571 matching lines...) Expand 10 before | Expand all | Expand 10 after
677 completion.Run(); 677 completion.Run();
678 } 678 }
679 679
680 void HttpServerPropertiesManager::OnHttpServerPropertiesChanged() { 680 void HttpServerPropertiesManager::OnHttpServerPropertiesChanged() {
681 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 681 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
682 if (!setting_prefs_) 682 if (!setting_prefs_)
683 ScheduleUpdateCacheOnUI(); 683 ScheduleUpdateCacheOnUI();
684 } 684 }
685 685
686 } // namespace chrome_browser_net 686 } // namespace chrome_browser_net
OLDNEW
« no previous file with comments | « chrome/browser/net/http_server_properties_manager.h ('k') | chrome/browser/net/net_pref_observer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698