OLD | NEW |
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 "chromeos/network/network_state.h" | 5 #include "chromeos/network/network_state.h" |
6 | 6 |
7 #include "base/i18n/icu_encoding_detection.h" | 7 #include "base/i18n/icu_encoding_detection.h" |
8 #include "base/i18n/icu_string_conversions.h" | 8 #include "base/i18n/icu_string_conversions.h" |
9 #include "base/json/json_writer.h" | 9 #include "base/json/json_writer.h" |
10 #include "base/strings/string_number_conversions.h" | 10 #include "base/strings/string_number_conversions.h" |
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
211 iter != wifi_frequencies_.end(); ++iter) { | 211 iter != wifi_frequencies_.end(); ++iter) { |
212 frequencies->AppendInteger(*iter); | 212 frequencies->AppendInteger(*iter); |
213 } | 213 } |
214 dictionary->SetWithoutPathExpansion(shill::kWifiFrequencyListProperty, | 214 dictionary->SetWithoutPathExpansion(shill::kWifiFrequencyListProperty, |
215 frequencies); | 215 frequencies); |
216 | 216 |
217 dictionary->SetStringWithoutPathExpansion(flimflam::kErrorProperty, | 217 dictionary->SetStringWithoutPathExpansion(flimflam::kErrorProperty, |
218 error_); | 218 error_); |
219 dictionary->SetStringWithoutPathExpansion(shill::kErrorDetailsProperty, | 219 dictionary->SetStringWithoutPathExpansion(shill::kErrorDetailsProperty, |
220 error_details_); | 220 error_details_); |
221 base::DictionaryValue* ipconfig_properties = new DictionaryValue; | 221 base::DictionaryValue* ipconfig_properties = new base::DictionaryValue; |
222 ipconfig_properties->SetStringWithoutPathExpansion(flimflam::kAddressProperty, | 222 ipconfig_properties->SetStringWithoutPathExpansion(flimflam::kAddressProperty, |
223 ip_address_); | 223 ip_address_); |
224 base::ListValue* name_servers = new ListValue; | 224 base::ListValue* name_servers = new base::ListValue; |
225 name_servers->AppendStrings(dns_servers_); | 225 name_servers->AppendStrings(dns_servers_); |
226 ipconfig_properties->SetWithoutPathExpansion(flimflam::kNameServersProperty, | 226 ipconfig_properties->SetWithoutPathExpansion(flimflam::kNameServersProperty, |
227 name_servers); | 227 name_servers); |
228 dictionary->SetWithoutPathExpansion(shill::kIPConfigProperty, | 228 dictionary->SetWithoutPathExpansion(shill::kIPConfigProperty, |
229 ipconfig_properties); | 229 ipconfig_properties); |
230 | 230 |
231 dictionary->SetStringWithoutPathExpansion(flimflam::kActivationStateProperty, | 231 dictionary->SetStringWithoutPathExpansion(flimflam::kActivationStateProperty, |
232 activation_state_); | 232 activation_state_); |
233 dictionary->SetStringWithoutPathExpansion(flimflam::kRoamingStateProperty, | 233 dictionary->SetStringWithoutPathExpansion(flimflam::kRoamingStateProperty, |
234 roaming_); | 234 roaming_); |
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
358 connection_state == flimflam::kStateConfiguration || | 358 connection_state == flimflam::kStateConfiguration || |
359 connection_state == flimflam::kStateCarrier); | 359 connection_state == flimflam::kStateCarrier); |
360 } | 360 } |
361 | 361 |
362 // static | 362 // static |
363 std::string NetworkState::IPConfigProperty(const char* key) { | 363 std::string NetworkState::IPConfigProperty(const char* key) { |
364 return base::StringPrintf("%s.%s", shill::kIPConfigProperty, key); | 364 return base::StringPrintf("%s.%s", shill::kIPConfigProperty, key); |
365 } | 365 } |
366 | 366 |
367 } // namespace chromeos | 367 } // namespace chromeos |
OLD | NEW |