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

Unified Diff: third_party/WebKit/Source/bindings/templates/interface.cpp.tmpl

Issue 2578943002: [Bindings] Refactoring of binding code around runtime enabled features (Closed)
Patch Set: Work for a comment Created 4 years 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: third_party/WebKit/Source/bindings/templates/interface.cpp.tmpl
diff --git a/third_party/WebKit/Source/bindings/templates/interface.cpp.tmpl b/third_party/WebKit/Source/bindings/templates/interface.cpp.tmpl
index 65454bed67a6c1649f3473343b87160554b3a022..f5c4467d013bbe48bc57df7082ca88adc30b0ae1 100644
--- a/third_party/WebKit/Source/bindings/templates/interface.cpp.tmpl
+++ b/third_party/WebKit/Source/bindings/templates/interface.cpp.tmpl
@@ -917,8 +917,8 @@ if (v8CallBoolean(prototypeObject->HasOwnProperty(context, unscopablesSymbol)))
unscopables = prototypeObject->Get(context, unscopablesSymbol).ToLocalChecked().As<v8::Object>();
else
unscopables = v8::Object::New(isolate);
-{% for name, runtime_enabled_function in unscopables %}
-{% filter runtime_enabled(runtime_enabled_function) %}
+{% for name, runtime_enabled_feature_name in unscopables %}
+{% filter runtime_enabled(runtime_enabled_feature_name) %}
unscopables->CreateDataProperty(context, v8AtomicString(isolate, "{{name}}"), v8::True(isolate)).FromJust();
{% endfilter %}
{% endfor %}
@@ -934,7 +934,7 @@ v8::Local<v8::Signature> signature = v8::Signature::New(isolate, interfaceTempla
{% for attribute in attributes if (attribute.exposed_test or attribute.secure_context_test) and attribute.on_prototype %}
{% filter exposed(attribute.exposed_test) %}
{% filter secure_context(attribute.secure_context_test) %}
-{% filter runtime_enabled(attribute.runtime_enabled_function) %}
+{% filter runtime_enabled(attribute.runtime_enabled_feature_name) %}
const V8DOMConfiguration::AccessorConfiguration accessorConfiguration = {{attribute_configuration(attribute)}};
V8DOMConfiguration::installAccessor(isolate, world, v8::Local<v8::Object>(), prototypeObject, interfaceObject, signature, accessorConfiguration);
{% endfilter %}{# runtime_enabled #}

Powered by Google App Engine
This is Rietveld 408576698