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

Side by Side Diff: mojo/public/tools/bindings/mojom.gni

Issue 2759563004: Mojo JS bindings: change module loading solution. (Closed)
Patch Set: . Created 3 years, 9 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
1 # Copyright 2014 The Chromium Authors. All rights reserved. 1 # Copyright 2014 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 declare_args() { 5 declare_args() {
6 # Indicates whether typemapping should be supported in this build 6 # Indicates whether typemapping should be supported in this build
7 # configuration. This may be disabled when building external projects which 7 # configuration. This may be disabled when building external projects which
8 # depend on //mojo but which do not need/want all of the Chromium tree 8 # depend on //mojo but which do not need/want all of the Chromium tree
9 # dependencies that come with typemapping. 9 # dependencies that come with typemapping.
10 # 10 #
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
127 # If set to true, generated classes will use base::OnceCallback instead of 127 # If set to true, generated classes will use base::OnceCallback instead of
128 # base::RepeatingCallback. 128 # base::RepeatingCallback.
129 # Default value is false. 129 # Default value is false.
130 # TODO(dcheng): 130 # TODO(dcheng):
131 # - Convert everything to use OnceCallback. 131 # - Convert everything to use OnceCallback.
132 # - Remove support for the old mode. 132 # - Remove support for the old mode.
133 # 133 #
134 # cpp_only (optional) 134 # cpp_only (optional)
135 # If set to true, only the C++ bindings targets will be generated. 135 # If set to true, only the C++ bindings targets will be generated.
136 # 136 #
137 # use_new_js_bindings (optional)
138 # If set to true, the generated JS code will use the new module loading
139 # approach and the core API exposed by Web IDL.
140 #
141 # TODO(yzshen): Switch all existing users to use_new_js_bindings=true and
142 # remove the old mode.
143 #
137 # The following parameters are used to support the component build. They are 144 # The following parameters are used to support the component build. They are
138 # needed so that bindings which are linked with a component can use the same 145 # needed so that bindings which are linked with a component can use the same
139 # export settings for classes. The first three are for the chromium variant, and 146 # export settings for classes. The first three are for the chromium variant, and
140 # the last three are for the blink variant. 147 # the last three are for the blink variant.
141 # export_class_attribute (optional) 148 # export_class_attribute (optional)
142 # The attribute to add to the class declaration. e.g. "CONTENT_EXPORT" 149 # The attribute to add to the class declaration. e.g. "CONTENT_EXPORT"
143 # export_define (optional) 150 # export_define (optional)
144 # A define to be added to the source_set which is needed by the export 151 # A define to be added to the source_set which is needed by the export
145 # header. e.g. "CONTENT_IMPLEMENTATION=1" 152 # header. e.g. "CONTENT_IMPLEMENTATION=1"
146 # export_header (optional) 153 # export_header (optional)
(...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after
427 invoker.export_class_attribute, 434 invoker.export_class_attribute,
428 "--export_header", 435 "--export_header",
429 invoker.export_header, 436 invoker.export_header,
430 ] 437 ]
431 } 438 }
432 } 439 }
433 440
434 if (defined(invoker.use_once_callback) && invoker.use_once_callback) { 441 if (defined(invoker.use_once_callback) && invoker.use_once_callback) {
435 args += [ "--use_once_callback" ] 442 args += [ "--use_once_callback" ]
436 } 443 }
444
445 if (defined(invoker.use_new_js_bindings) &&
446 invoker.use_new_js_bindings) {
447 args += [ "--use_new_js_bindings" ]
448 }
437 } 449 }
438 } 450 }
439 451
440 action(type_mappings_target_name) { 452 action(type_mappings_target_name) {
441 inputs = _bindings_configuration_files 453 inputs = _bindings_configuration_files
442 outputs = [ 454 outputs = [
443 type_mappings_path, 455 type_mappings_path,
444 ] 456 ]
445 script = "$mojom_generator_root/generate_type_mappings.py" 457 script = "$mojom_generator_root/generate_type_mappings.py"
446 deps = [] 458 deps = []
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after
640 full_name = get_label_info(d, "label_no_toolchain") 652 full_name = get_label_info(d, "label_no_toolchain")
641 deps += [ "${full_name}_java" ] 653 deps += [ "${full_name}_java" ]
642 } 654 }
643 655
644 srcjar_deps = [ ":$java_srcjar_target_name" ] 656 srcjar_deps = [ ":$java_srcjar_target_name" ]
645 run_findbugs_override = false 657 run_findbugs_override = false
646 } 658 }
647 } 659 }
648 } 660 }
649 } 661 }
OLDNEW
« no previous file with comments | « mojo/public/tools/bindings/generators/mojom_js_generator.py ('k') | mojo/public/tools/bindings/mojom_bindings_generator.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698