summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/WebGL/WebGLContextEvent.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Userland/Libraries/LibWeb/WebGL/WebGLContextEvent.cpp')
-rw-r--r--Userland/Libraries/LibWeb/WebGL/WebGLContextEvent.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/Userland/Libraries/LibWeb/WebGL/WebGLContextEvent.cpp b/Userland/Libraries/LibWeb/WebGL/WebGLContextEvent.cpp
index 363bdeeec5..343a8c2a0b 100644
--- a/Userland/Libraries/LibWeb/WebGL/WebGLContextEvent.cpp
+++ b/Userland/Libraries/LibWeb/WebGL/WebGLContextEvent.cpp
@@ -4,26 +4,26 @@
* SPDX-License-Identifier: BSD-2-Clause
*/
-#include <LibWeb/HTML/Window.h>
+#include <LibWeb/Bindings/Intrinsics.h>
#include <LibWeb/WebGL/WebGLContextEvent.h>
namespace Web::WebGL {
-WebGLContextEvent* WebGLContextEvent::create(HTML::Window& window_object, FlyString const& event_name, WebGLContextEventInit const& event_init)
+WebGLContextEvent* WebGLContextEvent::create(JS::Realm& realm, FlyString const& event_name, WebGLContextEventInit const& event_init)
{
- return window_object.heap().allocate<WebGLContextEvent>(window_object.realm(), window_object, event_name, event_init);
+ return realm.heap().allocate<WebGLContextEvent>(realm, realm, event_name, event_init);
}
-WebGLContextEvent* WebGLContextEvent::create_with_global_object(HTML::Window& window_object, FlyString const& event_name, WebGLContextEventInit const& event_init)
+WebGLContextEvent* WebGLContextEvent::construct_impl(JS::Realm& realm, FlyString const& event_name, WebGLContextEventInit const& event_init)
{
- return create(window_object, event_name, event_init);
+ return create(realm, event_name, event_init);
}
-WebGLContextEvent::WebGLContextEvent(HTML::Window& window_object, FlyString const& type, WebGLContextEventInit const& event_init)
- : DOM::Event(window_object, type, event_init)
+WebGLContextEvent::WebGLContextEvent(JS::Realm& realm, FlyString const& type, WebGLContextEventInit const& event_init)
+ : DOM::Event(realm, type, event_init)
, m_status_message(event_init.status_message)
{
- set_prototype(&window_object.cached_web_prototype("WebGLContextEvent"));
+ set_prototype(&Bindings::cached_web_prototype(realm, "WebGLContextEvent"));
}
WebGLContextEvent::~WebGLContextEvent() = default;