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

Unified Diff: chrome/browser/chromeos/cros/native_network_parser.cc

Issue 7714004: base: Add AsList() function to Value API. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: OVERRIDE Created 9 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
Index: chrome/browser/chromeos/cros/native_network_parser.cc
diff --git a/chrome/browser/chromeos/cros/native_network_parser.cc b/chrome/browser/chromeos/cros/native_network_parser.cc
index 31720250ea9fbbe3c87c1ac519809028a95d30e1..88ce2ce04b1239af6295c1684c54fb5514e36b75 100644
--- a/chrome/browser/chromeos/cros/native_network_parser.cc
+++ b/chrome/browser/chromeos/cros/native_network_parser.cc
@@ -194,7 +194,7 @@ bool NativeNetworkDeviceParser::ParseValue(
return true;
}
case PROPERTY_INDEX_CELLULAR_APN_LIST:
- if (value.IsType(Value::TYPE_LIST)) {
+ if (value.AsList()) {
CellularApnList provider_apn_list;
if (!ParseApnList(static_cast<const ListValue&>(value),
&provider_apn_list))
@@ -204,13 +204,13 @@ bool NativeNetworkDeviceParser::ParseValue(
}
break;
case PROPERTY_INDEX_NETWORKS:
- if (value.IsType(Value::TYPE_LIST)) {
+ if (value.AsList()) {
// Ignored.
return true;
}
break;
case PROPERTY_INDEX_FOUND_NETWORKS:
- if (value.IsType(Value::TYPE_LIST)) {
+ if (value.AsList()) {
CellularNetworkList found_cellular_networks;
if (!ParseFoundNetworksFromList(
static_cast<const ListValue&>(value),
Evan Martin 2011/08/23 18:15:26 We can remove the casts in this file with somethin
tfarina 2011/08/23 18:26:36 Done.

Powered by Google App Engine
This is Rietveld 408576698