X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali-toolkit%2Finternal%2Fvisuals%2Fanimated-vector-image%2Fvector-animation-manager.h;h=98794715da5cb8839c2031ddb015e125fce5cef0;hb=HEAD;hp=c52b800f6c3e278e7352eca9d5c4434014da400f;hpb=d0b0cfa4a44953be9af9128885eb6ef5d83a214e;p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git diff --git a/dali-toolkit/internal/visuals/animated-vector-image/vector-animation-manager.h b/dali-toolkit/internal/visuals/animated-vector-image/vector-animation-manager.h index c52b800..53dbb06 100644 --- a/dali-toolkit/internal/visuals/animated-vector-image/vector-animation-manager.h +++ b/dali-toolkit/internal/visuals/animated-vector-image/vector-animation-manager.h @@ -2,7 +2,7 @@ #define DALI_TOOLKIT_INTERNAL_VECTOR_ANIMATION_MANAGER_H /* - * Copyright (c) 2021 Samsung Electronics Co., Ltd. + * Copyright (c) 2024 Samsung Electronics Co., Ltd. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -19,6 +19,7 @@ */ // EXTERNAL INCLUDES +#include #include #include #include @@ -40,11 +41,6 @@ class VectorAnimationThread; class VectorAnimationManager : public Integration::Processor { public: - struct LifecycleObserver - { - virtual void VectorAnimationManagerDestroyed() = 0; - }; - /** * @brief Constructor. */ @@ -56,18 +52,6 @@ public: ~VectorAnimationManager() override; /** - * Add a lifecycle observer - * @param[in] observer The object watching this one - */ - void AddObserver(LifecycleObserver& observer); - - /** - * Remove a lifecycle observer - * @param[in] observer The object watching this one - */ - void RemoveObserver(LifecycleObserver& observer); - - /** * Get the vector animation thread. * @return A raw pointer pointing to the vector animation thread. */ @@ -92,7 +76,15 @@ protected: // Implementation of Processor /** * @copydoc Dali::Integration::Processor::Process() */ - void Process() override; + void Process(bool postProcessor) override; + + /** + * @copydoc Dali::Integration::Processor::GetProcessorName() + */ + std::string_view GetProcessorName() const override + { + return "VectorAnimationManager"; + } private: // Undefined @@ -102,10 +94,10 @@ private: VectorAnimationManager& operator=(const VectorAnimationManager& manager) = delete; private: - std::vector mEventCallbacks; - std::vector mLifecycleObservers; + Dali::Integration::OrderedSet mEventCallbacks; ///< Event triggered callback lists (owned) + std::unique_ptr mVectorAnimationThread; - bool mProcessorRegistered; + bool mProcessorRegistered : 1; }; } // namespace Internal