Chromium Code Reviews| Index: third_party/WebKit/Source/build/scripts/make_experimental_features.py |
| diff --git a/third_party/WebKit/Source/build/scripts/make_internal_runtime_flags.py b/third_party/WebKit/Source/build/scripts/make_experimental_features.py |
| similarity index 73% |
| copy from third_party/WebKit/Source/build/scripts/make_internal_runtime_flags.py |
| copy to third_party/WebKit/Source/build/scripts/make_experimental_features.py |
| index 216ed4314b407d5f86bf013cb2cf2a14652d2cbe..05fc835307f41f5794575a27bec3f657293c7068 100755 |
| --- a/third_party/WebKit/Source/build/scripts/make_internal_runtime_flags.py |
| +++ b/third_party/WebKit/Source/build/scripts/make_experimental_features.py |
| @@ -1,5 +1,5 @@ |
| #!/usr/bin/env python |
| -# Copyright (C) 2013 Google Inc. All rights reserved. |
| +# Copyright (C) 2015 Google Inc. All rights reserved. |
|
haraken
2015/12/24 15:46:51
Nit: You can use the 3-line copyright.
|
| # |
| # Redistribution and use in source and binary forms, with or without |
| # modification, are permitted provided that the following conditions are |
| @@ -27,7 +27,6 @@ |
| # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
| # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| -import os.path |
| import sys |
| import in_generator |
| @@ -38,33 +37,31 @@ import template_expander |
| # We want exactly the same parsing as RuntimeFeatureWriter |
| # but generate different files. |
| -class InternalRuntimeFlagsWriter(make_runtime_features.RuntimeFeatureWriter): |
| - class_name = 'InternalRuntimeFlags' |
| +class ExperimentalFeatureWriter(make_runtime_features.RuntimeFeatureWriter): |
| + class_name = 'ExperimentalFeatures' |
| filters = { |
| 'enable_conditional': name_utilities.enable_conditional_if_endif, |
| } |
| def __init__(self, in_file_path): |
| - super(InternalRuntimeFlagsWriter, self).__init__(in_file_path) |
| - self._outputs = {(self.class_name + '.idl'): self.generate_idl, |
| - (self.class_name + '.h'): self.generate_header, |
| - } |
| + super(ExperimentalFeatureWriter, self).__init__(in_file_path) |
| + self._outputs = { |
| + (self.class_name + '.cpp'): self.generate_implementation, |
| + (self.class_name + '.h'): self.generate_header, |
| + } |
| - @template_expander.use_jinja(class_name + '.idl.tmpl') |
| - def generate_idl(self): |
| + @template_expander.use_jinja(class_name + '.cpp.tmpl') |
| + def generate_implementation(self): |
| return { |
| 'features': self._features, |
| - 'standard_features': self._standard_features, |
| } |
| @template_expander.use_jinja(class_name + '.h.tmpl', filters=filters) |
| def generate_header(self): |
| return { |
| 'features': self._features, |
| - 'feature_sets': self._feature_sets(), |
| - 'standard_features': self._standard_features, |
| } |
| if __name__ == '__main__': |
| - in_generator.Maker(InternalRuntimeFlagsWriter).main(sys.argv) |
| + in_generator.Maker(ExperimentalFeatureWriter).main(sys.argv) |