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

Unified Diff: chromeos/network/network_state.cc

Issue 22796014: Eliminate c/b/chromeos/options/network_connect.cc (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 7 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chromeos/network/network_state.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromeos/network/network_state.cc
diff --git a/chromeos/network/network_state.cc b/chromeos/network/network_state.cc
index 7c85627aebc317013c0ed3fd0e8b571492c30e9c..0d0c790ee08a7cd1283b0fb2165819ff0b24b4ac 100644
--- a/chromeos/network/network_state.cc
+++ b/chromeos/network/network_state.cc
@@ -117,8 +117,6 @@ bool NetworkState::PropertyChanged(const std::string& key,
if (error_ == kErrorUnknown)
error_.clear();
return true;
- } else if (key == shill::kErrorDetailsProperty) {
- return GetStringValue(key, value, &error_details_);
} else if (key == IPConfigProperty(flimflam::kAddressProperty)) {
return GetStringValue(key, value, &ip_address_);
} else if (key == IPConfigProperty(flimflam::kGatewayProperty)) {
@@ -245,8 +243,6 @@ void NetworkState::GetProperties(base::DictionaryValue* dictionary) const {
dictionary->SetStringWithoutPathExpansion(flimflam::kErrorProperty,
error_);
- dictionary->SetStringWithoutPathExpansion(shill::kErrorDetailsProperty,
- error_details_);
// IPConfig properties
base::DictionaryValue* ipconfig_properties = new base::DictionaryValue;
@@ -355,13 +351,13 @@ bool NetworkState::UpdateName(const base::DictionaryValue& properties) {
std::string NetworkState::GetNameFromProperties(
const std::string& service_path,
const base::DictionaryValue& properties) {
- std::string name;
+ std::string name, hex_ssid;
properties.GetStringWithoutPathExpansion(flimflam::kNameProperty, &name);
-
- std::string hex_ssid;
properties.GetStringWithoutPathExpansion(flimflam::kWifiHexSsid, &hex_ssid);
if (hex_ssid.empty()) {
+ if (name.empty())
+ return name;
// Validate name for UTF8.
std::string valid_ssid = ValidateUTF8(name);
if (valid_ssid != name) {
« no previous file with comments | « chromeos/network/network_state.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698