Voice Chat fixes

This commit is contained in:
Ilya Laktyushin
2021-03-13 03:14:31 +04:00
parent 73657fc155
commit 67ac8b10c3
18 changed files with 4033 additions and 3939 deletions

View File

@@ -346,7 +346,13 @@ final class JoinLinkPreviewControllerNode: ViewControllerTracingNode, UIScrollVi
}
}
private var animatingOut = false
func animateOut(completion: (() -> Void)? = nil) {
guard !self.animatingOut else {
return
}
self.animatingOut = true
if self.contentNode != nil {
var dimCompleted = false
var offsetCompleted = false
@@ -354,6 +360,7 @@ final class JoinLinkPreviewControllerNode: ViewControllerTracingNode, UIScrollVi
let internalCompletion: () -> Void = { [weak self] in
if let strongSelf = self, dimCompleted && offsetCompleted {
strongSelf.dismiss?()
strongSelf.animatingOut = true
}
completion?()
}