From 90c932b703f477f14f7dd3e106b29563d6421811 Mon Sep 17 00:00:00 2001 From: bash Date: Sun, 16 Apr 2023 22:37:07 +0100 Subject: [PATCH] update lottie animation to swift 5.8 compatible --- RaveSDK/Classes/Utils/LoadingHUD.swift | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/RaveSDK/Classes/Utils/LoadingHUD.swift b/RaveSDK/Classes/Utils/LoadingHUD.swift index d65be5a..7700585 100644 --- a/RaveSDK/Classes/Utils/LoadingHUD.swift +++ b/RaveSDK/Classes/Utils/LoadingHUD.swift @@ -11,7 +11,7 @@ import Lottie class LoadingHUD: UIView { //let appDelegate = UIApplication.shared.delegate as? AppDelegate - var animation:AnimationView! + var animation:LottieAnimationView! var bgColor: UIColor? = .clear var applyBlur = true @@ -58,7 +58,7 @@ class LoadingHUD: UIView { } - animation = AnimationView(name: animationFile, bundle: Bundle.getResourcesBundle() ?? Bundle.main) + animation = LottieAnimationView(name: animationFile, bundle: Bundle.getResourcesBundle() ?? Bundle.main) animation.loopMode = .loop animation.translatesAutoresizingMaskIntoConstraints = false addSubview(animation) @@ -81,7 +81,7 @@ class LoadingHUD: UIView { blurView.bottomAnchor.constraint(equalTo: bottomAnchor).isActive = true } - animation = AnimationView(name: animationFile) + animation = LottieAnimationView(name: animationFile) animation.loopMode = .loop animation.translatesAutoresizingMaskIntoConstraints = false addSubview(animation)