1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-23 18:35:07 +00:00

LibWeb: Split JS wrapper constructors into construct/initialize

This commit is contained in:
Andreas Kling 2020-06-20 17:28:13 +02:00
parent 06e29fac57
commit 03da70c7d0
31 changed files with 107 additions and 55 deletions

View file

@ -41,10 +41,10 @@ XMLHttpRequestWrapper* wrap(JS::Heap& heap, XMLHttpRequest& impl)
return static_cast<XMLHttpRequestWrapper*>(wrap_impl(heap, impl));
}
XMLHttpRequestWrapper::XMLHttpRequestWrapper(XMLHttpRequest& impl)
: EventTargetWrapper(impl)
XMLHttpRequestWrapper::XMLHttpRequestWrapper(JS::GlobalObject& global_object, XMLHttpRequest& impl)
: EventTargetWrapper(global_object, impl)
{
set_prototype(static_cast<WindowObject&>(interpreter().global_object()).xhr_prototype());
set_prototype(static_cast<WindowObject&>(global_object).xhr_prototype());
}
XMLHttpRequestWrapper::~XMLHttpRequestWrapper()