add shouldRasterize true for animations

commit_hash:f38e387e47d0e8a26113dad0dbdb9a6274cc514c
This commit is contained in:
babaevmm
2026-04-09 23:01:41 +03:00
parent 6b6fc2b603
commit 0e33c20bf0
@@ -170,6 +170,7 @@ final class DetachableAnimationBlockView: BlockView, DelayedVisibilityActionView
childView.frame = convertFrame(to: container)
self.childView = nil
container.addSubview(childView)
childView.layer.shouldRasterize = true
childView.setInitialParamsAndAnimate(
animations: animationOut?.map { animation in
if animation.kind == .fade {
@@ -178,6 +179,7 @@ final class DetachableAnimationBlockView: BlockView, DelayedVisibilityActionView
return animation
},
completion: {
childView.layer.shouldRasterize = false
childView.removeFromSuperview()
}
)
@@ -194,9 +196,11 @@ final class DetachableAnimationBlockView: BlockView, DelayedVisibilityActionView
let item = DispatchWorkItem { [weak self] in
childView.isHidden = false
childView.layer.shouldRasterize = true
childView.setInitialParamsAndAnimate(
animations: animationIn.withDelay(-minDelay),
completion: { [weak self] in
childView.layer.shouldRasterize = false
self?.queuedAnimation = nil
self?.animationIn = nil
}