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

Unified Diff: third_party/WebKit/Source/bindings/scripts/v8_utilities.py

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/scripts/v8_utilities.py
diff --git a/third_party/WebKit/Source/bindings/scripts/v8_utilities.py b/third_party/WebKit/Source/bindings/scripts/v8_utilities.py
index e6fcb1d8b7ddcbe028ce515c66a6389c16a5272f..7ec15f2e8f05029a710e3bce18cba419cee1e2a1 100644
--- a/third_party/WebKit/Source/bindings/scripts/v8_utilities.py
+++ b/third_party/WebKit/Source/bindings/scripts/v8_utilities.py
@@ -374,18 +374,18 @@ def runtime_feature_name(definition_or_member):
return extended_attributes['RuntimeEnabled']
-def is_api_experiment_enabled(definition_or_member):
- return 'APIExperimentEnabled' in definition_or_member.extended_attributes
+def is_origin_trial_enabled(definition_or_member):
+ return 'OriginTrialEnabled' in definition_or_member.extended_attributes
-def api_experiment_name(definition_or_member):
- return definition_or_member.extended_attributes['APIExperimentEnabled'] if is_api_experiment_enabled(definition_or_member) else None
+def origin_trial_name(definition_or_member):
+ return definition_or_member.extended_attributes['OriginTrialEnabled'] if is_origin_trial_enabled(definition_or_member) else None
-def api_experiment_enabled_function(definition_or_member):
- experiment_name = api_experiment_name(definition_or_member)
+def origin_trial_enabled_function(definition_or_member):
+ trial_name = origin_trial_name(definition_or_member)
feature_name = runtime_feature_name(definition_or_member)
- if not feature_name or not experiment_name:
+ if not feature_name or not trial_name:
return
return 'OriginTrials::%sEnabled' % uncapitalize(feature_name)
@@ -400,13 +400,13 @@ def runtime_enabled_function_name(definition_or_member):
"""
feature_name = runtime_feature_name(definition_or_member)
- # If an API experiment is on the method/attribute, it overrides the runtime
- # enabled status. For now, we are unconditionally installing experimental
+ # If an origin trial is on the method/attribute, it overrides the runtime
+ # enabled status. For now, we are unconditionally installing these
# attributes/methods, so we are acting as though the runtime enabled
# function doesn't exist. (It is checked in the generated OriginTrials
# function, instead)
- experiment_name = api_experiment_name(definition_or_member)
- if not feature_name or experiment_name:
+ trial_name = origin_trial_name(definition_or_member)
+ if not feature_name or trial_name:
return
return 'RuntimeEnabledFeatures::%sEnabled' % uncapitalize(feature_name)
« no previous file with comments | « third_party/WebKit/Source/bindings/scripts/v8_methods.py ('k') | third_party/WebKit/Source/bindings/templates/attributes.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698