Various Fixes

This commit is contained in:
Ilya Laktyushin
2021-07-25 13:01:18 +03:00
parent 1f0646541d
commit c9d4c266dd
10 changed files with 52 additions and 33 deletions

View File

@@ -199,6 +199,9 @@ class ChatMessageInteractiveInstantVideoNode: ASDisplayNode {
break
}
}
if item.message.id.namespace == Namespaces.Message.Local {
notConsumed = true
}
var updatedPlaybackStatus: Signal<FileMediaResourceStatus, NoError>?
if let updatedFile = updatedFile, updatedMedia || updatedMessageId {
@@ -917,6 +920,7 @@ class ChatMessageInteractiveInstantVideoNode: ASDisplayNode {
}
}
private var animatedFadeIn = false
func animateFromSnapshot(snapshotView: UIView, transition: CombinedTransition) {
guard let videoFrame = self.videoFrame else {
return
@@ -934,9 +938,12 @@ class ChatMessageInteractiveInstantVideoNode: ASDisplayNode {
transition.horizontal.animateTransformScale(node: self, from: 1.0 / scale)
self.dateAndStatusNode.layer.animateAlpha(from: 0.0, to: self.dateAndStatusNode.alpha, duration: 0.15, delay: 0.18)
if let durationNode = self.durationNode {
durationNode.layer.animateAlpha(from: 0.0, to: durationNode.alpha, duration: 0.15, delay: 0.18)
if !self.animatedFadeIn {
self.animatedFadeIn = true
self.dateAndStatusNode.layer.animateAlpha(from: 0.0, to: self.dateAndStatusNode.alpha, duration: 0.15, delay: 0.18)
if let durationNode = self.durationNode {
durationNode.layer.animateAlpha(from: 0.0, to: durationNode.alpha, duration: 0.15, delay: 0.18)
}
}
}
}