| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # Copyright 2014 The Chromium Authors. All rights reserved. | 2 # Copyright 2014 The Chromium Authors. All rights reserved. |
| 3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
| 4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
| 5 | 5 |
| 6 import sys | 6 import sys |
| 7 import string | 7 import string |
| 8 import json | 8 import json |
| 9 | 9 |
| 10 blink_protocol_path = sys.argv[1] | 10 blink_protocol_path = sys.argv[1] |
| (...skipping 628 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 639 | 639 |
| 640 setters = [] | 640 setters = [] |
| 641 fields = [] | 641 fields = [] |
| 642 | 642 |
| 643 includes = [] | 643 includes = [] |
| 644 fields_init = [] | 644 fields_init = [] |
| 645 | 645 |
| 646 browser_domains_list = ["Input"] | 646 browser_domains_list = ["Input"] |
| 647 browser_commands_list = [] | 647 browser_commands_list = [] |
| 648 async_commands_list = [ | 648 async_commands_list = [ |
| 649 "Input.dispatchKeyEvent", |
| 650 "Input.dispatchMouseEvent", |
| 649 "Input.synthesizePinchGesture", | 651 "Input.synthesizePinchGesture", |
| 650 "Input.synthesizeScrollGesture", | 652 "Input.synthesizeScrollGesture", |
| 651 "Input.synthesizeTapGesture"] | 653 "Input.synthesizeTapGesture"] |
| 652 | 654 |
| 653 for json_domain in all_domains: | 655 for json_domain in all_domains: |
| 654 domain_map = {} | 656 domain_map = {} |
| 655 domain_map["Domain"] = json_domain["domain"] | 657 domain_map["Domain"] = json_domain["domain"] |
| 656 domain_map["domain"] = Uncamelcase(json_domain["domain"]) | 658 domain_map["domain"] = Uncamelcase(json_domain["domain"]) |
| 657 | 659 |
| 658 initializations = [] | 660 initializations = [] |
| (...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 810 output_h_file.close() | 812 output_h_file.close() |
| 811 | 813 |
| 812 output_cc_file.write(template_cc.substitute({}, | 814 output_cc_file.write(template_cc.substitute({}, |
| 813 major = blink_protocol["version"]["major"], | 815 major = blink_protocol["version"]["major"], |
| 814 minor = blink_protocol["version"]["minor"], | 816 minor = blink_protocol["version"]["minor"], |
| 815 includes = "".join(sorted(includes)), | 817 includes = "".join(sorted(includes)), |
| 816 fields_init = ",\n ".join(fields_init), | 818 fields_init = ",\n ".join(fields_init), |
| 817 methods = "\n".join(handler_method_impls), | 819 methods = "\n".join(handler_method_impls), |
| 818 types = "\n".join(type_impls))) | 820 types = "\n".join(type_impls))) |
| 819 output_cc_file.close() | 821 output_cc_file.close() |
| OLD | NEW |