mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 05:17:35 +00:00
LibWeb: Construct the IDL interface prototype chains automatically
Have each IDL prototype trigger the construction of its own prototype.
This commit is contained in:
parent
ee7fa49b88
commit
630cbc947a
3 changed files with 47 additions and 11 deletions
|
@ -217,13 +217,9 @@
|
|||
#include <LibWeb/Bindings/UIEventConstructor.h>
|
||||
#include <LibWeb/Bindings/UIEventPrototype.h>
|
||||
|
||||
#define ADD_WINDOW_OBJECT_INTERFACE(name) \
|
||||
{ \
|
||||
auto* prototype = heap().allocate<name##Prototype>(*this, *this); \
|
||||
name##Constructor* constructor = nullptr; \
|
||||
add_constructor(#name, constructor, prototype); \
|
||||
set_web_prototype(#name, prototype); \
|
||||
set_web_constructor(#name, constructor); \
|
||||
#define ADD_WINDOW_OBJECT_INTERFACE(name) \
|
||||
{ \
|
||||
ensure_web_constructor<name##Constructor>(#name); \
|
||||
}
|
||||
|
||||
#define ADD_WINDOW_OBJECT_INTERFACES \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue