1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-07 12:37:35 +00:00

LibWeb: Move bitmap animation from HTMLImageElement to ImageLoader

Since ImageLoader manages the image decoder anyway, let it manage
animation as well.
This commit is contained in:
Andreas Kling 2020-06-14 19:26:25 +02:00
parent 63b1c8e882
commit c45615128b
4 changed files with 51 additions and 44 deletions

View file

@ -28,7 +28,6 @@
#include <AK/ByteBuffer.h>
#include <AK/OwnPtr.h>
#include <LibCore/Forward.h>
#include <LibGfx/Forward.h>
#include <LibWeb/DOM/HTMLElement.h>
#include <LibWeb/Loader/ImageLoader.h>
@ -60,10 +59,6 @@ private:
virtual RefPtr<LayoutNode> create_layout_node(const StyleProperties* parent_style) const override;
ImageLoader m_image_loader;
size_t m_current_frame_index { 0 };
size_t m_loops_completed { 0 };
NonnullRefPtr<Core::Timer> m_timer;
};
template<>