mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 20:57:35 +00:00
LibWeb: Don't animate images outside the visible viewport :^)
This commit is contained in:
parent
73c9f7ebf4
commit
0072370459
1 changed files with 3 additions and 0 deletions
|
@ -87,6 +87,9 @@ void ImageLoader::resource_did_load()
|
||||||
|
|
||||||
void ImageLoader::animate()
|
void ImageLoader::animate()
|
||||||
{
|
{
|
||||||
|
if (!m_visible_in_viewport)
|
||||||
|
return;
|
||||||
|
|
||||||
auto* decoder = image_decoder();
|
auto* decoder = image_decoder();
|
||||||
ASSERT(decoder);
|
ASSERT(decoder);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue