OLD | NEW |
1 {% include 'copyright_block.txt' %} | 1 {% include 'copyright_block.txt' %} |
2 #ifndef {{v8_class}}_h | 2 #ifndef {{v8_class}}_h |
3 #define {{v8_class}}_h | 3 #define {{v8_class}}_h |
4 | 4 |
5 {% filter conditional(conditional_string) %} | 5 {% filter conditional(conditional_string) %} |
6 {% for filename in header_includes %} | 6 {% for filename in header_includes %} |
7 #include "{{filename}}" | 7 #include "{{filename}}" |
8 {% endfor %} | 8 {% endfor %} |
9 | 9 |
10 namespace blink { | 10 namespace blink { |
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
168 {{exported}}static void register{{method.name | blink_capitalize}}MethodForP
artialInterface(void (*)(const v8::FunctionCallbackInfo<v8::Value>&)); | 168 {{exported}}static void register{{method.name | blink_capitalize}}MethodForP
artialInterface(void (*)(const v8::FunctionCallbackInfo<v8::Value>&)); |
169 {% endfor %} | 169 {% endfor %} |
170 {% endif %} | 170 {% endif %} |
171 {% if has_partial_interface %} | 171 {% if has_partial_interface %} |
172 | 172 |
173 private: | 173 private: |
174 static InstallTemplateFunction install{{v8_class}}TemplateFunction; | 174 static InstallTemplateFunction install{{v8_class}}TemplateFunction; |
175 {% endif %} | 175 {% endif %} |
176 }; | 176 }; |
177 | 177 |
178 {% if has_custom_to_v8 %} | |
179 template<typename CallbackInfo> | |
180 inline void v8SetReturnValue(const CallbackInfo& callbackInfo, {{cpp_class}}* im
pl) | |
181 { | |
182 v8SetReturnValue(callbackInfo, toV8(impl, callbackInfo.Holder(), callbackInf
o.GetIsolate())); | |
183 } | |
184 | |
185 template<typename CallbackInfo> | |
186 inline void v8SetReturnValueForMainWorld(const CallbackInfo& callbackInfo, {{cpp
_class}}* impl) | |
187 { | |
188 v8SetReturnValue(callbackInfo, toV8(impl, callbackInfo.Holder(), callbackIn
fo.GetIsolate())); | |
189 } | |
190 | |
191 template<typename CallbackInfo> | |
192 inline void v8SetReturnValueFast(const CallbackInfo& callbackInfo, {{cpp_class}}
* impl, const ScriptWrappable*) | |
193 { | |
194 v8SetReturnValue(callbackInfo, toV8(impl, callbackInfo.Holder(), callbackIn
fo.GetIsolate())); | |
195 } | |
196 | |
197 {% endif %}{# has_custom_to_v8 #} | |
198 {% if has_event_constructor %} | 178 {% if has_event_constructor %} |
199 {{exported}}bool initialize{{cpp_class}}({{cpp_class}}Init&, const Dictionary&,
ExceptionState&, const v8::FunctionCallbackInfo<v8::Value>& info); | 179 {{exported}}bool initialize{{cpp_class}}({{cpp_class}}Init&, const Dictionary&,
ExceptionState&, const v8::FunctionCallbackInfo<v8::Value>& info); |
200 | 180 |
201 {% endif %} | 181 {% endif %} |
202 template <> | 182 template <> |
203 struct V8TypeOf<{{cpp_class}}> { | 183 struct V8TypeOf<{{cpp_class}}> { |
204 typedef {{v8_class}} Type; | 184 typedef {{v8_class}} Type; |
205 }; | 185 }; |
206 | 186 |
207 } // namespace blink | 187 } // namespace blink |
208 {% endfilter %} | 188 {% endfilter %} |
209 | 189 |
210 #endif // {{v8_class}}_h | 190 #endif // {{v8_class}}_h |
OLD | NEW |