From 5ce6fca802b21022c29aeae9a861b139bf851cef Mon Sep 17 00:00:00 2001 From: Hermet Park Date: Thu, 17 Apr 2025 15:16:38 +0900 Subject: [PATCH] api: fixed a build linking issue on lottie - something wrong with typeinfo missing in destructor (don't know reason) and this resolves the problem. - added override specifier for destructors --- inc/thorvg.h | 6 +++--- src/loaders/lottie/thorvg_lottie.h | 2 ++ src/loaders/lottie/tvgLottieAnimation.cpp | 5 ++--- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/inc/thorvg.h b/inc/thorvg.h index 28b70fb7..37df5293 100644 --- a/inc/thorvg.h +++ b/inc/thorvg.h @@ -1701,7 +1701,7 @@ public: class TVG_API SwCanvas final : public Canvas { public: - ~SwCanvas(); + ~SwCanvas() override; /** * @brief Sets the drawing target for the rasterization. @@ -1745,7 +1745,7 @@ public: class TVG_API GlCanvas final : public Canvas { public: - ~GlCanvas(); + ~GlCanvas() override; /** * @brief Sets the drawing target for rasterization. @@ -1794,7 +1794,7 @@ public: class TVG_API WgCanvas final : public Canvas { public: - ~WgCanvas(); + ~WgCanvas() override; /** * @brief Sets the drawing target for the rasterization. diff --git a/src/loaders/lottie/thorvg_lottie.h b/src/loaders/lottie/thorvg_lottie.h index 0ee3d221..b4607939 100644 --- a/src/loaders/lottie/thorvg_lottie.h +++ b/src/loaders/lottie/thorvg_lottie.h @@ -20,6 +20,8 @@ namespace tvg class TVG_API LottieAnimation final : public Animation { public: + ~LottieAnimation() override; + /** * @brief Override Lottie properties using slot data. * diff --git a/src/loaders/lottie/tvgLottieAnimation.cpp b/src/loaders/lottie/tvgLottieAnimation.cpp index 07c49d12..1ddb3889 100644 --- a/src/loaders/lottie/tvgLottieAnimation.cpp +++ b/src/loaders/lottie/tvgLottieAnimation.cpp @@ -26,9 +26,8 @@ #include "tvgAnimation.h" -LottieAnimation::LottieAnimation() -{ -} +LottieAnimation::LottieAnimation() = default; +LottieAnimation::~LottieAnimation() = default; Result LottieAnimation::override(const char* slot) noexcept