summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/DOM/Event.h
diff options
context:
space:
mode:
authorLinus Groh <mail@linusgroh.de>2021-02-17 22:52:40 +0100
committerAndreas Kling <kling@serenityos.org>2021-02-17 23:45:07 +0100
commit0ac07c73514233aa31daf29973c59fddfecf4a24 (patch)
treece1e33b42652b5b0d5b2ccdb0457bac4a6ea6522 /Userland/Libraries/LibWeb/DOM/Event.h
parent0f1da7d40c2ba0724f1b4d461aa1780f19c24bbf (diff)
downloadserenity-0ac07c73514233aa31daf29973c59fddfecf4a24.zip
LibWeb: Add constructor to Event IDL interface
Diffstat (limited to 'Userland/Libraries/LibWeb/DOM/Event.h')
-rw-r--r--Userland/Libraries/LibWeb/DOM/Event.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/Userland/Libraries/LibWeb/DOM/Event.h b/Userland/Libraries/LibWeb/DOM/Event.h
index 1acc60a386..54a91120e9 100644
--- a/Userland/Libraries/LibWeb/DOM/Event.h
+++ b/Userland/Libraries/LibWeb/DOM/Event.h
@@ -27,6 +27,7 @@
#pragma once
#include <AK/FlyString.h>
+#include <LibWeb/Bindings/WindowObject.h>
#include <LibWeb/Bindings/Wrappable.h>
#include <LibWeb/DOM/EventTarget.h>
@@ -64,6 +65,10 @@ public:
{
return adopt(*new Event(event_name));
}
+ static NonnullRefPtr<Event> create_with_global_object(Bindings::WindowObject&, const FlyString& event_name)
+ {
+ return Event::create(event_name);
+ }
virtual ~Event() { }