diff options
author | Andrew Kaster <akaster@serenityos.org> | 2022-09-25 18:12:50 -0600 |
---|---|---|
committer | Linus Groh <mail@linusgroh.de> | 2022-10-01 21:05:32 +0100 |
commit | beb3519a49e3ec91ccb142d690409082a98d9319 (patch) | |
tree | 6d6041d1fb77281af6ad72407bbc970b02fb3962 /Userland/Libraries/LibWeb/WebSockets/WebSocket.h | |
parent | 4bb6345b2ff348bd604b17c7dd4e81e61d52b658 (diff) | |
download | serenity-beb3519a49e3ec91ccb142d690409082a98d9319.zip |
LibWeb: Remove unecessary dependence on Window from WebGL and WebSocket
These classes only needed Window to get at its realm. Pass a realm
directly to construct WebGL and WebSocket classes.
Diffstat (limited to 'Userland/Libraries/LibWeb/WebSockets/WebSocket.h')
-rw-r--r-- | Userland/Libraries/LibWeb/WebSockets/WebSocket.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Userland/Libraries/LibWeb/WebSockets/WebSocket.h b/Userland/Libraries/LibWeb/WebSockets/WebSocket.h index f882120f24..47a542299b 100644 --- a/Userland/Libraries/LibWeb/WebSockets/WebSocket.h +++ b/Userland/Libraries/LibWeb/WebSockets/WebSocket.h @@ -37,7 +37,7 @@ public: Closed = 3, }; - static WebIDL::ExceptionOr<JS::NonnullGCPtr<WebSocket>> create_with_global_object(HTML::Window&, String const& url); + static WebIDL::ExceptionOr<JS::NonnullGCPtr<WebSocket>> construct_impl(JS::Realm&, String const& url); virtual ~WebSocket() override; @@ -66,7 +66,7 @@ private: void on_error(); void on_close(u16 code, String reason, bool was_clean); - explicit WebSocket(HTML::Window&, AK::URL&); + WebSocket(HTML::Window&, AK::URL&); virtual void visit_edges(Cell::Visitor&) override; |