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

Side by Side Diff: third_party/WebKit/Source/build/scripts/templates/OriginTrials.cpp.tmpl

Issue 1635593004: Rename Experimental Framework classes and concepts (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rename RuntimeEnabledFeatures flag to experimental_feature_name Created 4 years, 11 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 unified diff | Download patch
OLDNEW
(Empty)
1 {% from 'macros.tmpl' import license %}
2 {{license()}}
3
4 #include "core/origin_trials/OriginTrials.h"
5
6 #include "core/origin_trials/OriginTrialContext.h"
7 #include "platform/RuntimeEnabledFeatures.h"
8
9 namespace blink {
10 {% for feature in features %}
11 {% if feature.experimental_feature_name %}
chasej 2016/01/26 16:56:52 Subject to change, based on comment on naming for
iclelland 2016/01/26 19:05:48 Acknowledged.
iclelland 2016/01/27 18:56:46 Done.
12
13 // static
14 bool OriginTrials::{{feature.first_lowered_name}}Enabled(ExecutionContext* execu tionContext, String& errorMessage) {
15 return {{feature.first_lowered_name}}EnabledImpl(executionContext, &errorMes sage);
16 }
17
18 // static
19 bool OriginTrials::{{feature.first_lowered_name}}Enabled(ExecutionContext* execu tionContext) {
20 return {{feature.first_lowered_name}}EnabledImpl(executionContext, nullptr);
21 }
22 {% endif %}
23 {% endfor %}
24
25 {% for feature in features %}
26 {% if feature.experimental_feature_name %}
27
28 // static
29 bool OriginTrials::{{feature.first_lowered_name}}EnabledImpl(ExecutionContext* e xecutionContext, String* errorMessage) {
30 if (RuntimeEnabledFeatures::{{feature.first_lowered_name}}Enabled())
31 return true;
32 return OriginTrialContext::isFeatureEnabled(executionContext, "{{feature.exp erimental_feature_name}}", errorMessage);
33 }
34 {% endif %}
35 {% endfor %}
36
37 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698