Attachment menu improvements

This commit is contained in:
Ilya Laktyushin
2022-02-27 04:35:46 +04:00
parent ed4e86742d
commit 93476cf662
3 changed files with 4 additions and 1 deletions

View File

@@ -127,6 +127,7 @@ public class ImageNode: ASDisplayNode {
private var first = true
private let enableEmpty: Bool
public var enableAnimatedTransition: Bool
public var animateFirstTransition = true
private let _contentReady = Promise<Bool>()
private var didSetReady: Bool = false
@@ -166,7 +167,7 @@ public class ImageNode: ASDisplayNode {
if strongSelf.first && next != nil {
strongSelf.first = false
animate = false
if strongSelf.isNodeLoaded {
if strongSelf.isNodeLoaded && strongSelf.animateFirstTransition {
strongSelf.layer.animateAlpha(from: 0.0, to: 1.0, duration: 0.18)
}
}