mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-03 13:13:55 +00:00
Fix background progress
This commit is contained in:
parent
e5af882afe
commit
ae3d0be81f
@ -661,6 +661,7 @@ public final class MessageInlineBlockBackgroundView: UIView {
|
||||
} else {
|
||||
progressBackgroundContentsView = UIImageView()
|
||||
progressBackgroundContentsView.image = generateProgressTemplateImage()
|
||||
self.progressBackgroundContentsView = progressBackgroundContentsView
|
||||
self.insertSubview(progressBackgroundContentsView, aboveSubview: self.backgroundView)
|
||||
progressBackgroundContentsView.tintColor = primaryColor
|
||||
}
|
||||
@ -700,7 +701,9 @@ public final class MessageInlineBlockBackgroundView: UIView {
|
||||
if let progressBackgroundContentsView = self.progressBackgroundContentsView {
|
||||
self.progressBackgroundContentsView = nil
|
||||
let transition = ContainedViewLayoutTransition.animated(duration: 0.15, curve: .easeInOut)
|
||||
transition.updateAlpha(layer: progressBackgroundContentsView.layer, alpha: 0.0)
|
||||
transition.updateAlpha(layer: progressBackgroundContentsView.layer, alpha: 0.0, completion: { [weak progressBackgroundContentsView] _ in
|
||||
progressBackgroundContentsView?.removeFromSuperview()
|
||||
})
|
||||
}
|
||||
self.progressBackgroundMaskContainer = nil
|
||||
self.progressBackgroundGradientView = nil
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user