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

Side by Side Diff: chrome/browser/net/pref_proxy_config_tracker_impl.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
« no previous file with comments | « chrome/browser/net/predictor.cc ('k') | chrome/browser/net/pref_proxy_config_tracker_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_NET_PREF_PROXY_CONFIG_TRACKER_IMPL_H_ 5 #ifndef CHROME_BROWSER_NET_PREF_PROXY_CONFIG_TRACKER_IMPL_H_
6 #define CHROME_BROWSER_NET_PREF_PROXY_CONFIG_TRACKER_IMPL_H_ 6 #define CHROME_BROWSER_NET_PREF_PROXY_CONFIG_TRACKER_IMPL_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
116 net::ProxyConfig* effective_config); 116 net::ProxyConfig* effective_config);
117 117
118 // Converts a ProxyConfigDictionary to net::ProxyConfig representation. 118 // Converts a ProxyConfigDictionary to net::ProxyConfig representation.
119 // Returns true if the data from in the dictionary is valid, false otherwise. 119 // Returns true if the data from in the dictionary is valid, false otherwise.
120 static bool PrefConfigToNetConfig(const ProxyConfigDictionary& proxy_dict, 120 static bool PrefConfigToNetConfig(const ProxyConfigDictionary& proxy_dict,
121 net::ProxyConfig* config); 121 net::ProxyConfig* config);
122 122
123 // Registers the proxy preferences. These are actually registered 123 // Registers the proxy preferences. These are actually registered
124 // the same way in local state and in user prefs. 124 // the same way in local state and in user prefs.
125 static void RegisterPrefs(PrefRegistrySimple* registry); 125 static void RegisterPrefs(PrefRegistrySimple* registry);
126 static void RegisterUserPrefs(user_prefs::PrefRegistrySyncable* registry); 126 static void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry);
127 127
128 // Creates a proxy configuration from proxy-related preferences of 128 // Creates a proxy configuration from proxy-related preferences of
129 // |pref_service|. Configuration is stored in |config|, return value indicates 129 // |pref_service|. Configuration is stored in |config|, return value indicates
130 // whether the configuration is valid. 130 // whether the configuration is valid.
131 static ProxyPrefs::ConfigState ReadPrefConfig(const PrefService* pref_service, 131 static ProxyPrefs::ConfigState ReadPrefConfig(const PrefService* pref_service,
132 net::ProxyConfig* config); 132 net::ProxyConfig* config);
133 133
134 protected: 134 protected:
135 // Get the proxy configuration currently defined by preferences. 135 // Get the proxy configuration currently defined by preferences.
136 // Status is indicated in the return value. 136 // Status is indicated in the return value.
(...skipping 21 matching lines...) Expand all
158 158
159 PrefService* pref_service_; 159 PrefService* pref_service_;
160 ChromeProxyConfigService* chrome_proxy_config_service_; // Weak ptr. 160 ChromeProxyConfigService* chrome_proxy_config_service_; // Weak ptr.
161 bool update_pending_; // True if config has not been pushed to network stack. 161 bool update_pending_; // True if config has not been pushed to network stack.
162 PrefChangeRegistrar proxy_prefs_; 162 PrefChangeRegistrar proxy_prefs_;
163 163
164 DISALLOW_COPY_AND_ASSIGN(PrefProxyConfigTrackerImpl); 164 DISALLOW_COPY_AND_ASSIGN(PrefProxyConfigTrackerImpl);
165 }; 165 };
166 166
167 #endif // CHROME_BROWSER_NET_PREF_PROXY_CONFIG_TRACKER_IMPL_H_ 167 #endif // CHROME_BROWSER_NET_PREF_PROXY_CONFIG_TRACKER_IMPL_H_
OLDNEW
« no previous file with comments | « chrome/browser/net/predictor.cc ('k') | chrome/browser/net/pref_proxy_config_tracker_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698