mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-05-01 08:48:49 +00:00
UI: Prevent crash when right clicking on an unloaded image
This commit is contained in:
parent
57479c2d4b
commit
6fd03425b2
Notes:
github-actions[bot]
2025-01-12 19:30:53 +00:00
Author: https://github.com/Gingeh
Commit: 6fd03425b2
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/3210
Reviewed-by: https://github.com/tcl3 ✅
11 changed files with 43 additions and 20 deletions
|
@ -234,7 +234,7 @@ void WebContentClient::did_request_link_context_menu(u64 page_id, Gfx::IntPoint
|
|||
}
|
||||
}
|
||||
|
||||
void WebContentClient::did_request_image_context_menu(u64 page_id, Gfx::IntPoint content_position, URL::URL const& url, ByteString const&, unsigned, Gfx::ShareableBitmap const& bitmap)
|
||||
void WebContentClient::did_request_image_context_menu(u64 page_id, Gfx::IntPoint content_position, URL::URL const& url, ByteString const&, unsigned, Optional<Gfx::ShareableBitmap> const& bitmap)
|
||||
{
|
||||
if (auto view = view_for_page_id(page_id); view.has_value()) {
|
||||
if (view->on_image_context_menu_request)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue