| OLD | NEW |
| 1 {#- TODO(vardhan): This template produces crazy amounts of whitespace. Clean | 1 {#- TODO(vardhan): This template produces crazy amounts of whitespace. Clean |
| 2 this stuff up (it involves digging through all the templates included here. -#} | 2 this stuff up (it involves digging through all the templates included here. -#} |
| 3 // Copyright 2013 The Chromium Authors. All rights reserved. | 3 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 4 // Use of this source code is governed by a BSD-style license that can be | 4 // Use of this source code is governed by a BSD-style license that can be |
| 5 // found in the LICENSE file. | 5 // found in the LICENSE file. |
| 6 | 6 |
| 7 {%- import "struct_macros.tmpl" as struct_macros %} | 7 {%- import "struct_macros.tmpl" as struct_macros %} |
| 8 {% import "interface_macros.tmpl" as interface_macros -%} | 8 {% import "interface_macros.tmpl" as interface_macros -%} |
| 9 {%- set header_guard = "%s_H_"| | 9 {%- set header_guard = "%s_H_"| |
| 10 format(module.path|upper|replace("/","_")|replace(".","_")) %} | 10 format(module.path|upper|replace("/","_")|replace(".","_")) %} |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 {#------------------------ #} | 36 {#------------------------ #} |
| 37 | 37 |
| 38 {%- for namespace in namespaces_as_array %} | 38 {%- for namespace in namespaces_as_array %} |
| 39 namespace {{namespace}} { | 39 namespace {{namespace}} { |
| 40 {%- endfor %} | 40 {%- endfor %} |
| 41 | 41 |
| 42 {#--- Interface Forward Declarations -#} | 42 {#--- Interface Forward Declarations -#} |
| 43 {% for interface in interfaces %} | 43 {% for interface in interfaces %} |
| 44 class {{interface.name}}; | 44 class {{interface.name}}; |
| 45 using {{interface.name}}Ptr = mojo::InterfacePtr<{{interface.name}}>; | 45 using {{interface.name}}Ptr = mojo::InterfacePtr<{{interface.name}}>; |
| 46 using {{interface.name}}Handle = mojo::InterfaceHandle<{{interface.name}}>; |
| 46 {% endfor %} | 47 {% endfor %} |
| 47 | 48 |
| 48 {#--- Struct Forward Declarations -#} | 49 {#--- Struct Forward Declarations -#} |
| 49 {% for struct in structs %} | 50 {% for struct in structs %} |
| 50 {{ struct_macros.structptr_forward_decl(struct) }} | 51 {{ struct_macros.structptr_forward_decl(struct) }} |
| 51 {% endfor %} | 52 {% endfor %} |
| 52 | 53 |
| 53 {#--- Union Forward Declarations -#} | 54 {#--- Union Forward Declarations -#} |
| 54 {% for union in unions %} | 55 {% for union in unions %} |
| 55 class {{union.name}}; | 56 class {{union.name}}; |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 175 {#--- Request and response parameter structs for Interface methods -#} | 176 {#--- Request and response parameter structs for Interface methods -#} |
| 176 {% for interface in interfaces -%} | 177 {% for interface in interfaces -%} |
| 177 {{interface_macros.declare_param_structs_for_interface(interface)}} | 178 {{interface_macros.declare_param_structs_for_interface(interface)}} |
| 178 {%- endfor %} | 179 {%- endfor %} |
| 179 | 180 |
| 180 {%- for namespace in namespaces_as_array|reverse %} | 181 {%- for namespace in namespaces_as_array|reverse %} |
| 181 } // namespace {{namespace}} | 182 } // namespace {{namespace}} |
| 182 {%- endfor %} | 183 {%- endfor %} |
| 183 | 184 |
| 184 #endif // {{header_guard}} | 185 #endif // {{header_guard}} |
| OLD | NEW |