| Index: mojo/public/tools/bindings/generators/cpp_templates/interface_declaration.tmpl
|
| diff --git a/mojo/public/tools/bindings/generators/cpp_templates/interface_declaration.tmpl b/mojo/public/tools/bindings/generators/cpp_templates/interface_declaration.tmpl
|
| index 60fbfc52c7ea2ccec2278e1b09302cd8b053e083..d1c7e53b6b00e5ef3a91db7ff4745971fa609bad 100644
|
| --- a/mojo/public/tools/bindings/generators/cpp_templates/interface_declaration.tmpl
|
| +++ b/mojo/public/tools/bindings/generators/cpp_templates/interface_declaration.tmpl
|
| @@ -1,18 +1,18 @@
|
| {%- import "interface_macros.tmpl" as interface_macros %}
|
| class {{interface.name}}Proxy;
|
| class {{interface.name}}Stub;
|
| -{% if interface.peer %}
|
| -class {{interface.peer}};
|
| +{% if interface.client %}
|
| +class {{interface.client}};
|
| {% endif %}
|
|
|
| class {{interface.name}} {
|
| public:
|
| - typedef {{interface.name}}Proxy _Proxy;
|
| - typedef {{interface.name}}Stub _Stub;
|
| -{% if interface.peer %}
|
| - typedef {{interface.peer}} _Peer;
|
| + typedef {{interface.name}}Proxy Proxy_;
|
| + typedef {{interface.name}}Stub Stub_;
|
| +{% if interface.client %}
|
| + typedef {{interface.client}} Client_;
|
| {% else %}
|
| - typedef mojo::NoInterface _Peer;
|
| + typedef mojo::NoInterface Client_;
|
| {% endif %}
|
|
|
| {#--- Enums #}
|
| @@ -22,6 +22,13 @@ class {{interface.name}} {
|
| {%- endfor %}
|
|
|
| {#--- Methods #}
|
| + virtual ~{{interface.name}}() {}
|
| +{%- if interface.client %}
|
| + // Called once before any other method.
|
| + virtual void SetClient({{interface.client}}* client) = 0;
|
| +{%- else %}
|
| + virtual void SetClient(mojo::NoInterface* client) {}
|
| +{%- endif %}
|
| {%- for method in interface.methods %}
|
| virtual void {{method.name}}({{interface_macros.declare_request_params("", method)}}) = 0;
|
| {%- endfor %}
|
|
|