summaryrefslogtreecommitdiffstats
path: root/chrome/browser/chromeos/proxy_cros_settings_parser.cc
diff options
context:
space:
mode:
authorestade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-11-20 20:37:55 +0000
committerestade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-11-20 20:37:55 +0000
commit09d7a3aa84aa2b5f71c4ae65cb63c26e81bfb05e (patch)
tree78feb2452b9537b514c13fffa8e849700ac74547 /chrome/browser/chromeos/proxy_cros_settings_parser.cc
parent368be757a0f915b50048dc82e8ed9801c7a8a2b7 (diff)
downloadchromium_src-09d7a3aa84aa2b5f71c4ae65cb63c26e81bfb05e.zip
chromium_src-09d7a3aa84aa2b5f71c4ae65cb63c26e81bfb05e.tar.gz
chromium_src-09d7a3aa84aa2b5f71c4ae65cb63c26e81bfb05e.tar.bz2
Add copy and assignment to FundamentalValue and StringValue.
Also get rid of use of CreateStringValue in chromeos/ directory. This is a retry of r167808, but adding the copy and assign constructors fixes a clang compile error. BUG=160586 Review URL: https://chromiumcodereview.appspot.com/11418048 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@168868 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/chromeos/proxy_cros_settings_parser.cc')
-rw-r--r--chrome/browser/chromeos/proxy_cros_settings_parser.cc9
1 files changed, 4 insertions, 5 deletions
diff --git a/chrome/browser/chromeos/proxy_cros_settings_parser.cc b/chrome/browser/chromeos/proxy_cros_settings_parser.cc
index 2177095..5dc5e27 100644
--- a/chrome/browser/chromeos/proxy_cros_settings_parser.cc
+++ b/chrome/browser/chromeos/proxy_cros_settings_parser.cc
@@ -56,7 +56,7 @@ namespace {
base::Value* CreateServerHostValue(
const ProxyConfigServiceImpl::ProxyConfig::ManualProxy& proxy) {
return proxy.server.is_valid() ?
- base::Value::CreateStringValue(proxy.server.host_port_pair().host()) :
+ new base::StringValue(proxy.server.host_port_pair().host()) :
NULL;
}
@@ -298,8 +298,7 @@ bool GetProxyPrefValue(Profile* profile,
if (config.mode ==
chromeos::ProxyConfigServiceImpl::ProxyConfig::MODE_PAC_SCRIPT &&
config.automatic_proxy.pac_url.is_valid()) {
- data =
- base::Value::CreateStringValue(config.automatic_proxy.pac_url.spec());
+ data = new base::StringValue(config.automatic_proxy.pac_url.spec());
}
} else if (path == kProxySingleHttp) {
data = CreateServerHostValue(config.single_proxy);
@@ -357,7 +356,7 @@ bool GetProxyPrefValue(Profile* profile,
ListValue* list = new ListValue();
net::ProxyBypassRules::RuleList bypass_rules = config.bypass_rules.rules();
for (size_t x = 0; x < bypass_rules.size(); x++) {
- list->Append(base::Value::CreateStringValue(bypass_rules[x]->ToString()));
+ list->Append(new base::StringValue(bypass_rules[x]->ToString()));
}
data = list;
} else {
@@ -368,7 +367,7 @@ bool GetProxyPrefValue(Profile* profile,
// Decorate pref value as CoreOptionsHandler::CreateValueForPref() does.
DictionaryValue* dict = new DictionaryValue;
if (!data)
- data = base::Value::CreateStringValue("");
+ data = new base::StringValue("");
dict->Set("value", data);
if (path == kProxyType) {
dict->SetString("controlledBy", controlled_by);