| 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 {% for filename in header_includes %} | 5 {% for filename in header_includes %} |
| 6 #include "{{filename}}" | 6 #include "{{filename}}" |
| 7 {% endfor %} | 7 {% endfor %} |
| 8 | 8 |
| 9 namespace blink { | 9 namespace blink { |
| 10 | 10 |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 141 static const int eventListenerCacheIndex = v8DefaultWrapperInternalFieldCoun
t + {{custom_internal_field_counter}}; | 141 static const int eventListenerCacheIndex = v8DefaultWrapperInternalFieldCoun
t + {{custom_internal_field_counter}}; |
| 142 {% set custom_internal_field_counter = custom_internal_field_counter + 1 %} | 142 {% set custom_internal_field_counter = custom_internal_field_counter + 1 %} |
| 143 {% endif %} | 143 {% endif %} |
| 144 {# persistentHandleIndex must be the last field, if it is present. | 144 {# persistentHandleIndex must be the last field, if it is present. |
| 145 Detailed explanation: https://codereview.chromium.org/139173012 | 145 Detailed explanation: https://codereview.chromium.org/139173012 |
| 146 FIXME: Remove this internal field, and share one field for either: | 146 FIXME: Remove this internal field, and share one field for either: |
| 147 * a persistent handle (if the object is in oilpan) or | 147 * a persistent handle (if the object is in oilpan) or |
| 148 * a C++ pointer to the DOM object (if the object is not in oilpan) #} | 148 * a C++ pointer to the DOM object (if the object is not in oilpan) #} |
| 149 static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + {
{custom_internal_field_counter}}; | 149 static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + {
{custom_internal_field_counter}}; |
| 150 {# End custom internal fields #} | 150 {# End custom internal fields #} |
| 151 {% if interface_name == 'Window' %} | |
| 152 static bool securityCheckCustom(v8::Local<v8::Context> accessingContext, v8:
:Local<v8::Object> accessedObject, v8::Local<v8::Value> value); | |
| 153 {% endif %} | |
| 154 static void installConditionallyEnabledProperties(v8::Local<v8::Object>, v8:
:Isolate*){% if has_conditional_attributes %}; | 151 static void installConditionallyEnabledProperties(v8::Local<v8::Object>, v8:
:Isolate*){% if has_conditional_attributes %}; |
| 155 {% else %} { } | 152 {% else %} { } |
| 156 {% endif %} | 153 {% endif %} |
| 157 static void preparePrototypeAndInterfaceObject(v8::Local<v8::Context>, const
DOMWrapperWorld&, v8::Local<v8::Object> prototypeObject, v8::Local<v8::Function
> interfaceObject, v8::Local<v8::FunctionTemplate> interfaceTemplate){% if unsco
peables or has_conditional_attributes_on_prototype or conditionally_enabled_meth
ods %}; | 154 static void preparePrototypeAndInterfaceObject(v8::Local<v8::Context>, const
DOMWrapperWorld&, v8::Local<v8::Object> prototypeObject, v8::Local<v8::Function
> interfaceObject, v8::Local<v8::FunctionTemplate> interfaceTemplate){% if unsco
peables or has_conditional_attributes_on_prototype or conditionally_enabled_meth
ods %}; |
| 158 {% else %} { } | 155 {% else %} { } |
| 159 {% endif %} | 156 {% endif %} |
| 160 {% if has_partial_interface %} | 157 {% if has_partial_interface %} |
| 161 {{exported}}static void updateWrapperTypeInfo(InstallTemplateFunction, Prepa
rePrototypeAndInterfaceObjectFunction); | 158 {{exported}}static void updateWrapperTypeInfo(InstallTemplateFunction, Prepa
rePrototypeAndInterfaceObjectFunction); |
| 162 {{exported}}static void install{{v8_class}}Template(v8::Isolate*, const DOMW
rapperWorld&, v8::Local<v8::FunctionTemplate> interfaceTemplate); | 159 {{exported}}static void install{{v8_class}}Template(v8::Isolate*, const DOMW
rapperWorld&, v8::Local<v8::FunctionTemplate> interfaceTemplate); |
| 163 {% for method in methods if method.overloads and method.overloads.has_partia
l_overloads %} | 160 {% for method in methods if method.overloads and method.overloads.has_partia
l_overloads %} |
| (...skipping 12 matching lines...) Expand all Loading... |
| 176 | 173 |
| 177 {% endif %} | 174 {% endif %} |
| 178 template <> | 175 template <> |
| 179 struct V8TypeOf<{{cpp_class}}> { | 176 struct V8TypeOf<{{cpp_class}}> { |
| 180 typedef {{v8_class}} Type; | 177 typedef {{v8_class}} Type; |
| 181 }; | 178 }; |
| 182 | 179 |
| 183 } // namespace blink | 180 } // namespace blink |
| 184 | 181 |
| 185 #endif // {{v8_class}}_h | 182 #endif // {{v8_class}}_h |
| OLD | NEW |