1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-14 07:54:58 +00:00

LibWeb+LibWebView+WebContent: Add an Inspector IPC to execute JavaScript

The Inspector will have an <input> element to execute user-provided JS.
This adds an IDL method and IPC to forward that JS from the Inspector
WebView to the Inspector client.
This commit is contained in:
Timothy Flynn 2023-11-30 19:27:32 -05:00 committed by Andreas Kling
parent 060807e3da
commit 9f374a5d2a
10 changed files with 26 additions and 0 deletions

View file

@ -414,4 +414,10 @@ void WebContentClient::inspector_did_select_dom_node(i32 node_id, Optional<Web::
m_view.on_inspector_selected_dom_node(node_id, pseudo_element);
}
void WebContentClient::inspector_did_execute_console_script(String const& script)
{
if (m_view.on_inspector_executed_console_script)
m_view.on_inspector_executed_console_script(script);
}
}