![]() Since Web::Bindings::WindowObject inherits from JS::GlobalObject, it cannot also inherit from Web::Bindings::EventTargetWrapper. However, that's not actually necessary. Instead, we simply set the Window object's prototype to the EventTargetPrototype, and add a little extra branch in the impl_from() function that turns the JS "this" value into a DOM::EventTarget*. With this, you can now call window.addEventListener()! Very cool :^) Fixes #4758. |
||
---|---|---|
.. | ||
CMakeLists.txt | ||
Generate_CSS_PropertyID_cpp.cpp | ||
Generate_CSS_PropertyID_h.cpp | ||
Generate_CSS_ValueID_cpp.cpp | ||
Generate_CSS_ValueID_h.cpp | ||
WrapperGenerator.cpp |