mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-30 20:59:16 +00:00
LibWeb: Add in all of the plumbing required to use the JS console over IPC
This commit is contained in:
parent
51f073ff39
commit
0682af7b65
Notes:
sideshowbarker
2024-07-18 22:57:59 +09:00
Author: https://github.com/xeons
Commit: 0682af7b65
Pull-request: https://github.com/SerenityOS/serenity/pull/5556
5 changed files with 27 additions and 1 deletions
|
@ -320,6 +320,12 @@ void OutOfProcessWebView::notify_server_did_get_source(const URL& url, const Str
|
|||
on_get_source(url, source);
|
||||
}
|
||||
|
||||
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::did_scroll()
|
||||
{
|
||||
client().post_message(Messages::WebContentServer::SetViewportRect(visible_content_rect()));
|
||||
|
@ -351,4 +357,14 @@ void OutOfProcessWebView::get_source()
|
|||
client().post_message(Messages::WebContentServer::GetSource());
|
||||
}
|
||||
|
||||
void OutOfProcessWebView::js_console_initialize()
|
||||
{
|
||||
client().post_message(Messages::WebContentServer::JSConsoleInitialize());
|
||||
}
|
||||
|
||||
void OutOfProcessWebView::js_console_input(const String& js_source)
|
||||
{
|
||||
client().post_message(Messages::WebContentServer::JSConsoleInput(js_source));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue