diff --git a/Userland/Libraries/LibWeb/Animations/KeyframeEffect.h b/Userland/Libraries/LibWeb/Animations/KeyframeEffect.h index e39ad72ba4..191eb4c798 100644 --- a/Userland/Libraries/LibWeb/Animations/KeyframeEffect.h +++ b/Userland/Libraries/LibWeb/Animations/KeyframeEffect.h @@ -7,12 +7,12 @@ #pragma once #include +#include #include #include #include #include #include -#include namespace Web::Animations { @@ -58,6 +58,14 @@ class KeyframeEffect : public AnimationEffect { JS_DECLARE_ALLOCATOR(KeyframeEffect); public: + struct KeyFrameSet : public RefCounted { + struct UseInitial { }; + struct ResolvedKeyFrame { + HashMap>> resolved_properties {}; + }; + RedBlackTree keyframes_by_key; + }; + static JS::NonnullGCPtr create(JS::Realm&); static WebIDL::ExceptionOr> construct_impl( @@ -80,6 +88,9 @@ public: WebIDL::ExceptionOr> get_keyframes(); WebIDL::ExceptionOr set_keyframes(Optional> const&); + KeyFrameSet const* key_frame_set() { return m_key_frame_set; } + void set_key_frame_set(RefPtr key_frame_set) { m_key_frame_set = key_frame_set; } + private: KeyframeEffect(JS::Realm&); @@ -100,6 +111,8 @@ private: // A cached version of m_keyframes suitable for returning from get_keyframes() Vector m_keyframe_objects {}; + + RefPtr m_key_frame_set {}; }; }