diff options
author | danno@chromium.org <danno@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-01-13 12:23:06 +0000 |
---|---|---|
committer | danno@chromium.org <danno@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-01-13 12:23:06 +0000 |
commit | f0e63b4b3b44cb5a0f3099a7f3102d4fe7acf3a7 (patch) | |
tree | b0bc10591db36c04c36023a28dd88d10d7f7d50e /chrome/browser/prefs/proxy_prefs.cc | |
parent | 16c5c87e1296e597b259ad94d8eb7245bd7956a1 (diff) | |
download | chromium_src-f0e63b4b3b44cb5a0f3099a7f3102d4fe7acf3a7.zip chromium_src-f0e63b4b3b44cb5a0f3099a7f3102d4fe7acf3a7.tar.gz chromium_src-f0e63b4b3b44cb5a0f3099a7f3102d4fe7acf3a7.tar.bz2 |
Policy: Add ProxyMode and deprecate ProxyServerMode.
- Add support for 'deprecated' attribute in template generator
- Add support for both int- and string- based enums in the template generator
- Add logic to handle ProxyMode and fall back to ProxyServerMode
BUG=68134
TEST=ConfigurationPolicyPrefStore*, new policy template generator tests
Review URL: http://codereview.chromium.org/5958014
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@71315 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/prefs/proxy_prefs.cc')
-rw-r--r-- | chrome/browser/prefs/proxy_prefs.cc | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/chrome/browser/prefs/proxy_prefs.cc b/chrome/browser/prefs/proxy_prefs.cc index 7eb504c..fadd562 100644 --- a/chrome/browser/prefs/proxy_prefs.cc +++ b/chrome/browser/prefs/proxy_prefs.cc @@ -7,15 +7,25 @@ #include "base/basictypes.h" #include "base/logging.h" +namespace ProxyPrefs { + +const char kDirectProxyModeName[] = "direct"; +const char kAutoDetectProxyModeName[] = "auto_detect"; +const char kPacScriptProxyModeName[] = "pac_script"; +const char kFixedServersProxyModeName[] = "fixed_servers"; +const char kSystemProxyModeName[] = "system"; + +} + namespace { // These names are exposed to the proxy extension API. They must be in sync // with the constants of ProxyPrefs. -const char* kProxyModeNames[] = { "direct", - "auto_detect", - "pac_script", - "fixed_servers", - "system" }; +const char* kProxyModeNames[] = { ProxyPrefs::kDirectProxyModeName, + ProxyPrefs::kAutoDetectProxyModeName, + ProxyPrefs::kPacScriptProxyModeName, + ProxyPrefs::kFixedServersProxyModeName, + ProxyPrefs::kSystemProxyModeName }; } // namespace |