Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(603)

Side by Side Diff: third_party/WebKit/Source/bindings/templates/interface.h.tmpl

Issue 2620013002: binding: Supports preparePrototypeAndInterfaceObject on partial interfaces. (Closed)
Patch Set: Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 {% filter format_blink_cpp_source_code %} 1 {% filter format_blink_cpp_source_code %}
2 2
3 {% include 'copyright_block.txt' %} 3 {% include 'copyright_block.txt' %}
4 #ifndef {{v8_class}}_h 4 #ifndef {{v8_class}}_h
5 #define {{v8_class}}_h 5 #define {{v8_class}}_h
6 6
7 {% for filename in header_includes %} 7 {% for filename in header_includes %}
8 #include "{{filename}}" 8 #include "{{filename}}"
9 {% endfor %} 9 {% endfor %}
10 10
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 {# persistentHandleIndex must be the last field, if it is present. 132 {# persistentHandleIndex must be the last field, if it is present.
133 Detailed explanation: https://codereview.chromium.org/139173012 133 Detailed explanation: https://codereview.chromium.org/139173012
134 FIXME: Remove this internal field, and share one field for either: 134 FIXME: Remove this internal field, and share one field for either:
135 * a persistent handle (if the object is in oilpan) or 135 * a persistent handle (if the object is in oilpan) or
136 * a C++ pointer to the DOM object (if the object is not in oilpan) #} 136 * a C++ pointer to the DOM object (if the object is not in oilpan) #}
137 static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + {{c ustom_internal_field_counter}}; 137 static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + {{c ustom_internal_field_counter}};
138 {# End custom internal fields #} 138 {# End custom internal fields #}
139 {% if unscopables or has_conditional_attributes_on_prototype or 139 {% if unscopables or has_conditional_attributes_on_prototype or
140 methods | conditionally_exposed(is_partial) %} 140 methods | conditionally_exposed(is_partial) %}
141 {{exported}}static void preparePrototypeAndInterfaceObject(v8::Local<v8::Conte xt>, const DOMWrapperWorld&, v8::Local<v8::Object> prototypeObject, v8::Local<v8 ::Function> interfaceObject, v8::Local<v8::FunctionTemplate> interfaceTemplate); 141 {{exported}}static void preparePrototypeAndInterfaceObject(v8::Local<v8::Conte xt>, const DOMWrapperWorld&, v8::Local<v8::Object> prototypeObject, v8::Local<v8 ::Function> interfaceObject, v8::Local<v8::FunctionTemplate> interfaceTemplate);
142 {% elif has_partial_interface %}
143 {{exported}}static void preparePrototypeAndInterfaceObject(v8::Local<v8::Conte xt>, const DOMWrapperWorld&, v8::Local<v8::Object> prototypeObject, v8::Local<v8 ::Function> interfaceObject, v8::Local<v8::FunctionTemplate> interfaceTemplate) {}
142 {% endif %} 144 {% endif %}
143 {% if has_partial_interface %} 145 {% if has_partial_interface %}
144 {{exported}}static void updateWrapperTypeInfo(InstallTemplateFunction, Prepare PrototypeAndInterfaceObjectFunction); 146 {{exported}}static void updateWrapperTypeInfo(InstallTemplateFunction, Prepare PrototypeAndInterfaceObjectFunction);
145 {{exported}}static void install{{v8_class}}Template(v8::Isolate*, const DOMWra pperWorld&, v8::Local<v8::FunctionTemplate> interfaceTemplate); 147 {{exported}}static void install{{v8_class}}Template(v8::Isolate*, const DOMWra pperWorld&, v8::Local<v8::FunctionTemplate> interfaceTemplate);
146 {% for method in methods if method.overloads and method.overloads.has_partial_ overloads %} 148 {% for method in methods if method.overloads and method.overloads.has_partial_ overloads %}
147 {{exported}}static void register{{method.name | blink_capitalize}}MethodForPar tialInterface(void (*)(const v8::FunctionCallbackInfo<v8::Value>&)); 149 {{exported}}static void register{{method.name | blink_capitalize}}MethodForPar tialInterface(void (*)(const v8::FunctionCallbackInfo<v8::Value>&));
148 {% endfor %} 150 {% endfor %}
149 {% endif %} 151 {% endif %}
150 152
151 {% for feature in origin_trial_features %} 153 {% for feature in origin_trial_features %}
(...skipping 18 matching lines...) Expand all
170 template <> 172 template <>
171 struct V8TypeOf<{{cpp_class}}> { 173 struct V8TypeOf<{{cpp_class}}> {
172 typedef {{v8_class}} Type; 174 typedef {{v8_class}} Type;
173 }; 175 };
174 176
175 } // namespace blink 177 } // namespace blink
176 178
177 #endif // {{v8_class}}_h 179 #endif // {{v8_class}}_h
178 180
179 {% endfilter %}{# format_blink_cpp_source_code #} 181 {% endfilter %}{# format_blink_cpp_source_code #}
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698