| OLD | NEW |
| 1 {# http://www.chromium.org/blink/coding-style#TOC-License #} | 1 {# http://www.chromium.org/blink/coding-style#TOC-License #} |
| 2 /* | 2 /* |
| 3 * Copyright (C) 2013 Google Inc. All rights reserved. | 3 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
| 7 * met: | 7 * met: |
| 8 * | 8 * |
| 9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 28 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
| 29 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 29 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 30 */ | 30 */ |
| 31 | 31 |
| 32 {# FIXME: Rename to Python when switch #} | 32 {# FIXME: Rename to Python when switch #} |
| 33 // This file has been auto-generated by code_generator_v8.pm. DO NOT MODIFY! | 33 // This file has been auto-generated by code_generator_v8.pm. DO NOT MODIFY! |
| 34 | 34 |
| 35 #ifndef {{v8_class_name}}_h | 35 #ifndef {{v8_class_name}}_h |
| 36 #define {{v8_class_name}}_h | 36 #define {{v8_class_name}}_h |
| 37 | 37 |
| 38 {% if conditional_string %} | 38 {% filter conditional(conditional_string) %} |
| 39 #if {{conditional_string}} | |
| 40 {% endif %} | |
| 41 {% for filename in header_includes %} | 39 {% for filename in header_includes %} |
| 42 #include "{{filename}}" | 40 #include "{{filename}}" |
| 43 {% endfor %} | 41 {% endfor %} |
| 44 | 42 |
| 45 namespace WebCore { | 43 namespace WebCore { |
| 46 | 44 |
| 47 class {{v8_class_name}} { | 45 class {{v8_class_name}} { |
| 48 public: | 46 public: |
| 49 static bool hasInstance(v8::Handle<v8::Value>, v8::Isolate*, WrapperWorldTyp
e); | 47 static bool hasInstance(v8::Handle<v8::Value>, v8::Isolate*, WrapperWorldTyp
e); |
| 50 static bool hasInstanceInAnyWorld(v8::Handle<v8::Value>, v8::Isolate*); | 48 static bool hasInstanceInAnyWorld(v8::Handle<v8::Value>, v8::Isolate*); |
| (...skipping 20 matching lines...) Expand all Loading... |
| 71 {% filter conditional(attribute.conditional_string) %} | 69 {% filter conditional(attribute.conditional_string) %} |
| 72 static void {{attribute.name}}AttributeGetterCustom(const v8::PropertyCallba
ckInfo<v8::Value>&); | 70 static void {{attribute.name}}AttributeGetterCustom(const v8::PropertyCallba
ckInfo<v8::Value>&); |
| 73 {% endfilter %} | 71 {% endfilter %} |
| 74 {% endif %} | 72 {% endif %} |
| 75 {% if attribute.has_custom_setter %}{# FIXME: and not attribute.implemented_
by #} | 73 {% if attribute.has_custom_setter %}{# FIXME: and not attribute.implemented_
by #} |
| 76 {% filter conditional(attribute.conditional_string) %} | 74 {% filter conditional(attribute.conditional_string) %} |
| 77 static void {{attribute.name}}AttributeSetterCustom(v8::Local<v8::Value>, co
nst v8::PropertyCallbackInfo<void>&); | 75 static void {{attribute.name}}AttributeSetterCustom(v8::Local<v8::Value>, co
nst v8::PropertyCallbackInfo<void>&); |
| 78 {% endfilter %} | 76 {% endfilter %} |
| 79 {% endif %} | 77 {% endif %} |
| 80 {% endfor %} | 78 {% endfor %} |
| 79 {% if has_custom_legacy_call %} |
| 80 static void legacyCallCustom(const v8::FunctionCallbackInfo<v8::Value>&); |
| 81 {% endif %} |
| 81 static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0
; | 82 static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0
; |
| 82 static inline void* toInternalPointer({{cpp_class_name}}* impl) | 83 static inline void* toInternalPointer({{cpp_class_name}}* impl) |
| 83 { | 84 { |
| 84 return impl; | 85 return impl; |
| 85 } | 86 } |
| 86 | 87 |
| 87 static inline {{cpp_class_name}}* fromInternalPointer(void* object) | 88 static inline {{cpp_class_name}}* fromInternalPointer(void* object) |
| 88 { | 89 { |
| 89 return static_cast<{{cpp_class_name}}*>(object); | 90 return static_cast<{{cpp_class_name}}*>(object); |
| 90 } | 91 } |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 180 v8SetReturnValueForMainWorld(callbackInfo, impl.get()); | 181 v8SetReturnValueForMainWorld(callbackInfo, impl.get()); |
| 181 } | 182 } |
| 182 | 183 |
| 183 template<class CallbackInfo, class Wrappable> | 184 template<class CallbackInfo, class Wrappable> |
| 184 inline void v8SetReturnValueFast(const CallbackInfo& callbackInfo, PassRefPtr<{{
cpp_class_name}} > impl, Wrappable* wrappable) | 185 inline void v8SetReturnValueFast(const CallbackInfo& callbackInfo, PassRefPtr<{{
cpp_class_name}} > impl, Wrappable* wrappable) |
| 185 { | 186 { |
| 186 v8SetReturnValueFast(callbackInfo, impl.get(), wrappable); | 187 v8SetReturnValueFast(callbackInfo, impl.get(), wrappable); |
| 187 } | 188 } |
| 188 | 189 |
| 189 } | 190 } |
| 190 {% if conditional_string %} | 191 {% endfilter %} |
| 191 | |
| 192 #endif // {{conditional_string}} | |
| 193 {% endif %} | |
| 194 | |
| 195 #endif // {{v8_class_name}}_h | 192 #endif // {{v8_class_name}}_h |
| OLD | NEW |