From f73487b61bdeb7eeec1c6908d2b3df78e87ee449 Mon Sep 17 00:00:00 2001 From: Heeyong Song Date: Mon, 25 Nov 2019 13:42:42 +0900 Subject: [PATCH] [Tizen] (Vector) Call Finalize method instead of deleting VectorRenderer Change-Id: Id7d0a5cab4229e6619122c6294914d512bae9b17 --- .../toolkit-vector-animation-renderer.cpp | 9 ++++----- .../visuals/animated-vector-image/vector-animation-task.cpp | 2 +- .../visuals/animated-vector-image/vector-rasterize-thread.cpp | 6 +++--- 3 files changed, 8 insertions(+), 9 deletions(-) diff --git a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-vector-animation-renderer.cpp b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-vector-animation-renderer.cpp index f8c0c36..b039c57 100755 --- a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-vector-animation-renderer.cpp +++ b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-vector-animation-renderer.cpp @@ -108,10 +108,6 @@ public: height = 100; } - void GetLayerInfo( Property::Map& map ) const - { - } - Dali::VectorAnimationRenderer::UploadCompletedSignalType& UploadCompletedSignal() { return mUploadCompletedSignal; @@ -186,6 +182,10 @@ VectorAnimationRenderer& VectorAnimationRenderer::operator=( const VectorAnimati return *this; } +void VectorAnimationRenderer::Finalize() +{ +} + void VectorAnimationRenderer::SetRenderer( Renderer renderer ) { Internal::Adaptor::GetImplementation( *this ).SetRenderer( renderer ); @@ -218,7 +218,6 @@ void VectorAnimationRenderer::GetDefaultSize( uint32_t& width, uint32_t& height void VectorAnimationRenderer::GetLayerInfo( Property::Map& map ) const { - Internal::Adaptor::GetImplementation( *this ).GetLayerInfo( map ); } VectorAnimationRenderer::UploadCompletedSignalType& VectorAnimationRenderer::UploadCompletedSignal() diff --git a/dali-toolkit/internal/visuals/animated-vector-image/vector-animation-task.cpp b/dali-toolkit/internal/visuals/animated-vector-image/vector-animation-task.cpp index 2579229..379ebc5 100644 --- a/dali-toolkit/internal/visuals/animated-vector-image/vector-animation-task.cpp +++ b/dali-toolkit/internal/visuals/animated-vector-image/vector-animation-task.cpp @@ -102,7 +102,7 @@ void VectorAnimationTask::Finalize() mAnimationFinishedTrigger.reset(); } - mVectorRenderer.Reset(); + mVectorRenderer.Finalize(); } void VectorAnimationTask::SetRenderer( Renderer renderer ) diff --git a/dali-toolkit/internal/visuals/animated-vector-image/vector-rasterize-thread.cpp b/dali-toolkit/internal/visuals/animated-vector-image/vector-rasterize-thread.cpp index cb2d08a..08cad31 100644 --- a/dali-toolkit/internal/visuals/animated-vector-image/vector-rasterize-thread.cpp +++ b/dali-toolkit/internal/visuals/animated-vector-image/vector-rasterize-thread.cpp @@ -76,15 +76,15 @@ void VectorRasterizeThread::SetCompletedCallback( CallbackBase* callback ) void VectorRasterizeThread::AddTask( VectorAnimationTaskPtr task ) { + // Lock while adding task to the queue + ConditionalWait::ScopedLock lock( mConditionalWait ); + if( !mIsThreadStarted ) { Start(); mIsThreadStarted = true; } - // Lock while adding task to the queue - ConditionalWait::ScopedLock lock( mConditionalWait ); - if( mRasterizeTasks.end() == std::find( mRasterizeTasks.begin(), mRasterizeTasks.end(), task ) ) { mRasterizeTasks.push_back( task ); -- 2.7.4