mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-10-22 16:09:23 +00:00
LibWeb: Support decoding SVG favicons
Adds a path that checks if blob contains SVG image before reaching for image decoder. Fixes logged image decoding errors on https://chatgpt.com/
This commit is contained in:
parent
f9888b0641
commit
77f6edaf71
Notes:
github-actions[bot]
2025-08-27 06:42:04 +00:00
Author: https://github.com/kalenikaliaksandr
Commit: 77f6edaf71
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5988
Reviewed-by: https://github.com/gmta ✅
Reviewed-by: https://github.com/konradekk
3 changed files with 29 additions and 5 deletions
|
@ -30,7 +30,7 @@ namespace Web::SVG {
|
|||
GC_DEFINE_ALLOCATOR(SVGDecodedImageData);
|
||||
GC_DEFINE_ALLOCATOR(SVGDecodedImageData::SVGPageClient);
|
||||
|
||||
ErrorOr<GC::Ref<SVGDecodedImageData>> SVGDecodedImageData::create(JS::Realm& realm, GC::Ref<Page> host_page, URL::URL const& url, ByteBuffer data)
|
||||
ErrorOr<GC::Ref<SVGDecodedImageData>> SVGDecodedImageData::create(JS::Realm& realm, GC::Ref<Page> host_page, URL::URL const& url, ReadonlyBytes data)
|
||||
{
|
||||
auto page_client = SVGPageClient::create(Bindings::main_thread_vm(), host_page);
|
||||
auto page = Page::create(Bindings::main_thread_vm(), *page_client);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue