mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 05:17:35 +00:00
LibWeb: Invalidate element when setting AnimationEffect's animation
This commit is contained in:
parent
ce99636cd0
commit
6d25bf3aac
2 changed files with 9 additions and 1 deletions
|
@ -8,6 +8,7 @@
|
|||
#include <LibWeb/Animations/Animation.h>
|
||||
#include <LibWeb/Animations/AnimationEffect.h>
|
||||
#include <LibWeb/Bindings/Intrinsics.h>
|
||||
#include <LibWeb/DOM/Element.h>
|
||||
#include <LibWeb/WebIDL/ExceptionOr.h>
|
||||
|
||||
namespace Web::Animations {
|
||||
|
@ -153,6 +154,13 @@ WebIDL::ExceptionOr<void> AnimationEffect::update_timing(OptionalEffectTiming ti
|
|||
return {};
|
||||
}
|
||||
|
||||
void AnimationEffect::set_associated_animation(JS::GCPtr<Animation> value)
|
||||
{
|
||||
m_associated_animation = value;
|
||||
if (auto* target = this->target())
|
||||
target->invalidate_style();
|
||||
}
|
||||
|
||||
// https://www.w3.org/TR/web-animations-1/#animation-direction
|
||||
AnimationDirection AnimationEffect::animation_direction() const
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue