mirror of
https://github.com/divkit/divkit.git
synced 2026-06-06 20:07:59 +00:00
fb117357b4
Support RiveRuntime
29 lines
677 B
Swift
29 lines
677 B
Swift
import AVFoundation
|
|
import UIKit
|
|
|
|
import CommonCore
|
|
import LayoutKit
|
|
|
|
extension LottieAnimationBlock {
|
|
static func makeBlockView() -> BlockView {
|
|
AnimationBlockView()
|
|
}
|
|
|
|
func canConfigureBlockView(_ view: BlockView) -> Bool {
|
|
view is AnimationBlockView
|
|
}
|
|
|
|
func configureBlockView(
|
|
_ view: BlockView,
|
|
observer _: ElementStateObserver?,
|
|
overscrollDelegate _: ScrollDelegate?,
|
|
renderingDelegate _: RenderingDelegate?
|
|
) {
|
|
let lottieView = view as! AnimationBlockView
|
|
if lottieView.animationHolder !== animationHolder {
|
|
lottieView.animatableView = animatableView.value
|
|
lottieView.animationHolder = animationHolder
|
|
}
|
|
}
|
|
}
|