diff --git a/Userland/Libraries/LibWeb/OutOfProcessWebView.cpp b/Userland/Libraries/LibWeb/OutOfProcessWebView.cpp index 19ca8c47f9..ae74ff24dd 100644 --- a/Userland/Libraries/LibWeb/OutOfProcessWebView.cpp +++ b/Userland/Libraries/LibWeb/OutOfProcessWebView.cpp @@ -347,12 +347,6 @@ void OutOfProcessWebView::notify_server_did_get_dom_node_properties(i32 node_id, on_get_dom_node_properties(node_id, specified_style, computed_style); } -void OutOfProcessWebView::notify_server_did_js_console_output(const String& method, const String& line) -{ - if (on_js_console_output) - on_js_console_output(method, line); -} - void OutOfProcessWebView::notify_server_did_output_js_console_message(i32 message_index) { if (on_js_console_new_message) @@ -441,11 +435,6 @@ i32 OutOfProcessWebView::get_hovered_node_id() return client().get_hovered_node_id(); } -void OutOfProcessWebView::js_console_initialize() -{ - client().async_js_console_initialize(); -} - void OutOfProcessWebView::js_console_input(const String& js_source) { client().async_js_console_input(js_source); diff --git a/Userland/Libraries/LibWeb/OutOfProcessWebView.h b/Userland/Libraries/LibWeb/OutOfProcessWebView.h index d63db9dc27..a5df3b771b 100644 --- a/Userland/Libraries/LibWeb/OutOfProcessWebView.h +++ b/Userland/Libraries/LibWeb/OutOfProcessWebView.h @@ -41,7 +41,6 @@ public: void clear_inspected_dom_node(); i32 get_hovered_node_id(); - void js_console_initialize(); void js_console_input(const String& js_source); void js_console_request_messages(i32 start_index); @@ -75,7 +74,6 @@ public: void notify_server_did_get_source(const URL& url, const String& source); void notify_server_did_get_dom_tree(const String& dom_tree); void notify_server_did_get_dom_node_properties(i32 node_id, String const& specified_style, String const& computed_style); - void notify_server_did_js_console_output(const String& method, const String& line); void notify_server_did_output_js_console_message(i32 message_index); void notify_server_did_get_js_console_messages(i32 start_index, Vector const& message_types, Vector const& messages); void notify_server_did_change_favicon(const Gfx::Bitmap& favicon); diff --git a/Userland/Libraries/LibWeb/WebContentClient.cpp b/Userland/Libraries/LibWeb/WebContentClient.cpp index 25e3e28204..b248e32f88 100644 --- a/Userland/Libraries/LibWeb/WebContentClient.cpp +++ b/Userland/Libraries/LibWeb/WebContentClient.cpp @@ -146,11 +146,6 @@ void WebContentClient::did_get_dom_node_properties(i32 node_id, String const& sp m_view.notify_server_did_get_dom_node_properties(node_id, specified_style, computed_style); } -void WebContentClient::did_js_console_output(String const& method, String const& line) -{ - m_view.notify_server_did_js_console_output(method, line); -} - void WebContentClient::did_output_js_console_message(i32 message_index) { m_view.notify_server_did_output_js_console_message(message_index); diff --git a/Userland/Libraries/LibWeb/WebContentClient.h b/Userland/Libraries/LibWeb/WebContentClient.h index 65ee0c4298..328b07a66b 100644 --- a/Userland/Libraries/LibWeb/WebContentClient.h +++ b/Userland/Libraries/LibWeb/WebContentClient.h @@ -51,7 +51,6 @@ private: virtual void did_get_source(URL const&, String const&) override; virtual void did_get_dom_tree(String const&) override; virtual void did_get_dom_node_properties(i32 node_id, String const& specified_style, String const& computed_style) override; - virtual void did_js_console_output(String const&, String const&) override; virtual void did_output_js_console_message(i32 message_index) override; virtual void did_get_js_console_messages(i32 start_index, Vector const& message_types, Vector const& messages) override; virtual void did_change_favicon(Gfx::ShareableBitmap const&) override; diff --git a/Userland/Libraries/LibWeb/WebViewHooks.h b/Userland/Libraries/LibWeb/WebViewHooks.h index 3bdb5386a5..f8bcde5c92 100644 --- a/Userland/Libraries/LibWeb/WebViewHooks.h +++ b/Userland/Libraries/LibWeb/WebViewHooks.h @@ -29,7 +29,6 @@ public: Function on_get_source; Function on_get_dom_tree; Function on_get_dom_node_properties; - Function on_js_console_output; Function on_js_console_new_message; Function const& message_types, Vector const& messages)> on_get_js_console_messages; Function on_get_cookie; diff --git a/Userland/Services/WebContent/ClientConnection.cpp b/Userland/Services/WebContent/ClientConnection.cpp index 0e1eda7639..30654f9977 100644 --- a/Userland/Services/WebContent/ClientConnection.cpp +++ b/Userland/Services/WebContent/ClientConnection.cpp @@ -270,19 +270,6 @@ Messages::WebContentServer::GetHoveredNodeIdResponse ClientConnection::get_hover return (i32)0; } -void ClientConnection::js_console_initialize() -{ - if (auto* document = page().top_level_browsing_context().document()) { - auto interpreter = document->interpreter().make_weak_ptr(); - if (m_interpreter.ptr() == interpreter.ptr()) - return; - - m_interpreter = interpreter; - m_console_client = make(interpreter->global_object().console(), interpreter, *this); - interpreter->global_object().console().set_client(*m_console_client.ptr()); - } -} - void ClientConnection::initialize_js_console(Badge) { auto* document = page().top_level_browsing_context().document(); diff --git a/Userland/Services/WebContent/ClientConnection.h b/Userland/Services/WebContent/ClientConnection.h index 77232f1ba4..506f04414d 100644 --- a/Userland/Services/WebContent/ClientConnection.h +++ b/Userland/Services/WebContent/ClientConnection.h @@ -55,7 +55,6 @@ private: virtual Messages::WebContentServer::InspectDomNodeResponse inspect_dom_node(i32) override; virtual Messages::WebContentServer::GetHoveredNodeIdResponse get_hovered_node_id() override; - virtual void js_console_initialize() override; virtual void js_console_input(String const&) override; virtual void run_javascript(String const&) override; virtual void js_console_request_messages(i32) override; diff --git a/Userland/Services/WebContent/WebContentClient.ipc b/Userland/Services/WebContent/WebContentClient.ipc index ca1edbdb36..427cf8c0c9 100644 --- a/Userland/Services/WebContent/WebContentClient.ipc +++ b/Userland/Services/WebContent/WebContentClient.ipc @@ -29,7 +29,6 @@ endpoint WebContentClient did_get_source(URL url, String source) =| did_get_dom_tree(String dom_tree) =| did_get_dom_node_properties(i32 node_id, String specified_style, String computed_style) =| - did_js_console_output(String method, String line) =| did_change_favicon(Gfx::ShareableBitmap favicon) =| did_request_cookie(URL url, u8 source) => (String cookie) did_set_cookie(URL url, Web::Cookie::ParsedCookie cookie, u8 source) =| diff --git a/Userland/Services/WebContent/WebContentServer.ipc b/Userland/Services/WebContent/WebContentServer.ipc index 23da9c81c1..b7006efeba 100644 --- a/Userland/Services/WebContent/WebContentServer.ipc +++ b/Userland/Services/WebContent/WebContentServer.ipc @@ -29,7 +29,6 @@ endpoint WebContentServer inspect_dom_tree() =| inspect_dom_node(i32 node_id) => (bool has_style, String specified_style, String computed_style) get_hovered_node_id() => (i32 node_id) - js_console_initialize() =| js_console_input(String js_source) =| js_console_request_messages(i32 start_index) =|