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

Unified Diff: chrome/renderer/extensions/v8_schema_registry.cc

Issue 15091002: Lazily load API schemas from resource files and convert all APIs to features (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: optimize and "parent" property Created 7 years, 7 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/renderer/extensions/v8_schema_registry.cc
diff --git a/chrome/renderer/extensions/v8_schema_registry.cc b/chrome/renderer/extensions/v8_schema_registry.cc
index 5aa785f4d12d092c7c13e9c132fed60c6e9951a2..e11f2c85b8ac13d9880119ca7e5603b9b23d5e15 100644
--- a/chrome/renderer/extensions/v8_schema_registry.cc
+++ b/chrome/renderer/extensions/v8_schema_registry.cc
@@ -25,14 +25,14 @@ V8SchemaRegistry::~V8SchemaRegistry() {
}
v8::Handle<v8::Array> V8SchemaRegistry::GetSchemas(
- const std::set<std::string>& apis) {
+ const std::vector<std::string>& apis) {
v8::HandleScope handle_scope;
v8::Context::Scope context_scope(GetOrCreateContext());
v8::Handle<v8::Array> v8_apis(v8::Array::New(apis.size()));
size_t api_index = 0;
- for (std::set<std::string>::const_iterator i = apis.begin(); i != apis.end();
- ++i) {
+ for (std::vector<std::string>::const_iterator i = apis.begin();
+ i != apis.end(); ++i) {
v8_apis->Set(api_index++, GetSchema(*i));
}
return handle_scope.Close(v8_apis);

Powered by Google App Engine
This is Rietveld 408576698