OLD | NEW |
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 "chrome/browser/prefs/command_line_pref_store.h" | 5 #include "chrome/browser/prefs/command_line_pref_store.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
8 #include "base/values.h" | 8 #include "base/values.h" |
9 #include "chrome/browser/prefs/proxy_config_dictionary.h" | 9 #include "chrome/browser/prefs/proxy_config_dictionary.h" |
10 #include "chrome/common/chrome_switches.h" | 10 #include "chrome/common/chrome_switches.h" |
(...skipping 12 matching lines...) Expand all Loading... |
23 | 23 |
24 const CommandLinePrefStore::BooleanSwitchToPreferenceMapEntry | 24 const CommandLinePrefStore::BooleanSwitchToPreferenceMapEntry |
25 CommandLinePrefStore::boolean_switch_map_[] = { | 25 CommandLinePrefStore::boolean_switch_map_[] = { |
26 { switches::kDisableAuthNegotiateCnameLookup, | 26 { switches::kDisableAuthNegotiateCnameLookup, |
27 prefs::kDisableAuthNegotiateCnameLookup, true }, | 27 prefs::kDisableAuthNegotiateCnameLookup, true }, |
28 { switches::kEnableAuthNegotiatePort, prefs::kEnableAuthNegotiatePort, | 28 { switches::kEnableAuthNegotiatePort, prefs::kEnableAuthNegotiatePort, |
29 true }, | 29 true }, |
30 { switches::kDisable3DAPIs, prefs::kDisable3DAPIs, true }, | 30 { switches::kDisable3DAPIs, prefs::kDisable3DAPIs, true }, |
31 { switches::kEnableCloudPrintProxy, prefs::kCloudPrintProxyEnabled, | 31 { switches::kEnableCloudPrintProxy, prefs::kCloudPrintProxyEnabled, |
32 true }, | 32 true }, |
| 33 { switches::kNoPings, prefs::kEnableHyperlinkAuditing, false }, |
| 34 { switches::kNoReferrers, prefs::kEnableReferrers, false }, |
33 }; | 35 }; |
34 | 36 |
35 CommandLinePrefStore::CommandLinePrefStore(const CommandLine* command_line) | 37 CommandLinePrefStore::CommandLinePrefStore(const CommandLine* command_line) |
36 : command_line_(command_line) { | 38 : command_line_(command_line) { |
37 ApplySimpleSwitches(); | 39 ApplySimpleSwitches(); |
38 ApplyProxyMode(); | 40 ApplyProxyMode(); |
39 ValidateProxySwitches(); | 41 ValidateProxySwitches(); |
40 } | 42 } |
41 | 43 |
42 CommandLinePrefStore::~CommandLinePrefStore() {} | 44 CommandLinePrefStore::~CommandLinePrefStore() {} |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
88 } else if (command_line_->HasSwitch(switches::kProxyServer)) { | 90 } else if (command_line_->HasSwitch(switches::kProxyServer)) { |
89 std::string proxy_server = | 91 std::string proxy_server = |
90 command_line_->GetSwitchValueASCII(switches::kProxyServer); | 92 command_line_->GetSwitchValueASCII(switches::kProxyServer); |
91 std::string bypass_list = | 93 std::string bypass_list = |
92 command_line_->GetSwitchValueASCII(switches::kProxyBypassList); | 94 command_line_->GetSwitchValueASCII(switches::kProxyBypassList); |
93 SetValue(prefs::kProxy, | 95 SetValue(prefs::kProxy, |
94 ProxyConfigDictionary::CreateFixedServers(proxy_server, | 96 ProxyConfigDictionary::CreateFixedServers(proxy_server, |
95 bypass_list)); | 97 bypass_list)); |
96 } | 98 } |
97 } | 99 } |
OLD | NEW |