mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 17:27:35 +00:00
Ladybird: Fix broken favicon conversion from Gfx::Bitmap to QPixmap
This commit is contained in:
parent
48de1fb1b1
commit
a7cb558783
1 changed files with 1 additions and 2 deletions
|
@ -207,8 +207,7 @@ public:
|
||||||
|
|
||||||
virtual void page_did_change_favicon(Gfx::Bitmap const& bitmap) override
|
virtual void page_did_change_favicon(Gfx::Bitmap const& bitmap) override
|
||||||
{
|
{
|
||||||
ByteBuffer bytebuffer = bitmap.serialize_to_byte_buffer();
|
QPixmap icon = QPixmap::fromImage(QImage(bitmap.scanline_u8(0), bitmap.width(), bitmap.height(), bitmap.pitch(), QImage::Format_ARGB32));
|
||||||
QPixmap icon = QPixmap::fromImage(QImage(bytebuffer.bytes().data(), bitmap.width(), bitmap.height(), QImage::Format_ARGB32));
|
|
||||||
emit m_view.favicon_changed(QIcon(icon));
|
emit m_view.favicon_changed(QIcon(icon));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue