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

Unified Diff: extensions/renderer/api_binding.cc

Issue 2740143002: Change base::Value::ListStorage to std::vector<base::Value> (Closed)
Patch Set: Fix Android Compilation Error Created 3 years, 9 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: extensions/renderer/api_binding.cc
diff --git a/extensions/renderer/api_binding.cc b/extensions/renderer/api_binding.cc
index 7016ec288bf6cea7b482858c21b7896867e20a10..18e1d2574a925d3693e7c8d14499ac57ac073bda 100644
--- a/extensions/renderer/api_binding.cc
+++ b/extensions/renderer/api_binding.cc
@@ -174,7 +174,7 @@ APIBinding::APIBinding(const std::string& api_name,
if (function_definitions) {
for (const auto& func : *function_definitions) {
const base::DictionaryValue* func_dict = nullptr;
- CHECK(func->GetAsDictionary(&func_dict));
+ CHECK(func.GetAsDictionary(&func_dict));
std::string name;
CHECK(func_dict->GetString("name", &name));
@@ -191,7 +191,7 @@ APIBinding::APIBinding(const std::string& api_name,
if (type_definitions) {
for (const auto& type : *type_definitions) {
const base::DictionaryValue* type_dict = nullptr;
- CHECK(type->GetAsDictionary(&type_dict));
+ CHECK(type.GetAsDictionary(&type_dict));
std::string id;
CHECK(type_dict->GetString("id", &id));
auto argument_spec = base::MakeUnique<ArgumentSpec>(*type_dict);
@@ -216,7 +216,7 @@ APIBinding::APIBinding(const std::string& api_name,
if (type_dict->GetList("functions", &type_functions)) {
for (const auto& func : *type_functions) {
const base::DictionaryValue* func_dict = nullptr;
- CHECK(func->GetAsDictionary(&func_dict));
+ CHECK(func.GetAsDictionary(&func_dict));
std::string function_name;
CHECK(func_dict->GetString("name", &function_name));
@@ -234,7 +234,7 @@ APIBinding::APIBinding(const std::string& api_name,
events_.reserve(event_definitions->GetSize());
for (const auto& event : *event_definitions) {
const base::DictionaryValue* event_dict = nullptr;
- CHECK(event->GetAsDictionary(&event_dict));
+ CHECK(event.GetAsDictionary(&event_dict));
std::string name;
CHECK(event_dict->GetString("name", &name));
std::string full_name =
@@ -259,8 +259,8 @@ APIBinding::APIBinding(const std::string& api_name,
const base::ListValue* list = nullptr;
CHECK(options->GetList(name, &list));
for (const auto& entry : *list) {
- DCHECK(entry->is_string());
- out_value->push_back(entry->GetString());
+ DCHECK(entry.is_string());
+ out_value->push_back(entry.GetString());
}
};
get_values("actions", &rule_actions);

Powered by Google App Engine
This is Rietveld 408576698