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

Unified Diff: third_party/WebKit/Source/bindings/templates/utilities.cpp

Issue 1685393002: [Experimental Framework] Rename IDL attribute to OriginTrialEnabled (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Change existing usage of APIExperimentEnabled Created 4 years, 10 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: third_party/WebKit/Source/bindings/templates/utilities.cpp
diff --git a/third_party/WebKit/Source/bindings/templates/utilities.cpp b/third_party/WebKit/Source/bindings/templates/utilities.cpp
index 7ad315924c113ff56b9a82017087ed1baf10cdde..6391fec80c9e05c9ef44364f6f52f3911c946a8b 100644
--- a/third_party/WebKit/Source/bindings/templates/utilities.cpp
+++ b/third_party/WebKit/Source/bindings/templates/utilities.cpp
@@ -55,10 +55,10 @@ const char* validValues[] = {
{%- endmacro %}
-{% macro check_api_experiment_internal(errorName, experiment_name) %}
-{% if experiment_name %}
+{% macro check_origin_trial_internal(errorName, origin_trial_name) %}
+{% if origin_trial_name %}
String {{errorName}};
-if (!{{experiment_name}}(executionContext, {{errorName}})) {
+if (!{{origin_trial_name}}(executionContext, {{errorName}})) {
v8SetReturnValue(info, v8::Undefined(info.GetIsolate()));
if (!{{errorName}}.isEmpty()) {
toDocument(executionContext)->addConsoleMessage(ConsoleMessage::create(JSMessageSource, ErrorMessageLevel, {{errorName}}));
@@ -69,8 +69,8 @@ if (!{{experiment_name}}(executionContext, {{errorName}})) {
{% endmacro %}
-{% macro check_api_experiment(member, isolate="info.GetIsolate()") -%}
+{% macro check_origin_trial(member, isolate="info.GetIsolate()") -%}
ExecutionContext* executionContext = currentExecutionContext({{isolate}});
-{{check_api_experiment_internal("errorMessage", member.api_experiment_enabled_per_interface) -}}
-{{check_api_experiment_internal("memberErrorMessage", member.api_experiment_enabled) -}}
+{{check_origin_trial_internal("errorMessage", member.origin_trial_enabled_per_interface) -}}
+{{check_origin_trial_internal("memberErrorMessage", member.origin_trial_enabled) -}}
{% endmacro %}

Powered by Google App Engine
This is Rietveld 408576698