LibWeb: Set animation update flag from Animation::invalidate_effect()

Fixes regressed animation tests.
This commit is contained in:
Aliaksandr Kalenik 2024-03-21 14:49:30 +01:00 committed by Alexander Kalenik
commit 42d5883d57
Notes: sideshowbarker 2024-07-17 02:21:14 +09:00
3 changed files with 4 additions and 3 deletions

View file

@ -1316,8 +1316,10 @@ JS::NonnullGCPtr<WebIDL::Promise> Animation::current_finished_promise() const
void Animation::invalidate_effect()
{
if (m_effect) {
if (auto target = m_effect->target(); target && target->paintable())
if (auto target = m_effect->target(); target && target->paintable()) {
target->document().set_needs_animated_style_update();
target->paintable()->set_needs_display();
}
}
}