mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-18 08:20:44 +00:00
LibWebView+WebContent+headless-browser: Make the page info IPCs async
The IPCs to request a page's text, layout tree, etc. are currently all synchronous. This can result in a deadlock when WebContent also makes a synchronous IPC call, as both ends will be waiting on each other. This replaces the page info IPCs with a single, asynchronous IPC. This new IPC is promise-based, much like our screenshot IPC.
This commit is contained in:
parent
b688bbf26c
commit
3332230cef
Notes:
github-actions[bot]
2024-09-19 16:08:09 +00:00
Author: https://github.com/trflynn89
Commit: 3332230cef
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1447
11 changed files with 174 additions and 90 deletions
|
@ -71,7 +71,7 @@ static bool is_primitive_type(ByteString const& type)
|
|||
static bool is_simple_type(ByteString const& type)
|
||||
{
|
||||
// Small types that it makes sense just to pass by value.
|
||||
return type.is_one_of("AK::CaseSensitivity", "Gfx::Color", "Web::DevicePixels", "Gfx::IntPoint", "Gfx::FloatPoint", "Web::DevicePixelPoint", "Gfx::IntSize", "Gfx::FloatSize", "Web::DevicePixelSize", "Core::File::OpenMode", "Web::Cookie::Source", "Web::EventResult", "Web::HTML::AllowMultipleFiles", "Web::HTML::AudioPlayState", "Web::HTML::HistoryHandlingBehavior");
|
||||
return type.is_one_of("AK::CaseSensitivity", "Gfx::Color", "Web::DevicePixels", "Gfx::IntPoint", "Gfx::FloatPoint", "Web::DevicePixelPoint", "Gfx::IntSize", "Gfx::FloatSize", "Web::DevicePixelSize", "Core::File::OpenMode", "Web::Cookie::Source", "Web::EventResult", "Web::HTML::AllowMultipleFiles", "Web::HTML::AudioPlayState", "Web::HTML::HistoryHandlingBehavior", "WebView::PageInfoType");
|
||||
}
|
||||
|
||||
static bool is_primitive_or_simple_type(ByteString const& type)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue