mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-11-07 01:10:09 +00:00
Fix checks tooltip
This commit is contained in:
parent
544b3fa08e
commit
d82cb247d2
@ -15232,7 +15232,7 @@ public final class ChatControllerImpl: TelegramBaseController, ChatController, G
|
||||
|
||||
if let (_, latestStatusNode) = latestNode {
|
||||
let bounds = latestStatusNode.view.convert(latestStatusNode.view.bounds, to: self.chatDisplayNode.view)
|
||||
let location = CGPoint(x: bounds.maxX - 7.0, y: bounds.minY + 2.0)
|
||||
let location = CGPoint(x: bounds.maxX - 7.0, y: bounds.minY - 11.0)
|
||||
|
||||
let contentNode = ChatStatusChecksTooltipContentNode(presentationData: self.presentationData)
|
||||
let tooltipController = TooltipController(content: .custom(contentNode), baseFontSize: self.presentationData.listsFontSize.baseDisplaySize, timeout: 3.5, dismissByTapOutside: true, dismissImmediatelyOnLayoutUpdate: true)
|
||||
|
||||
@ -196,32 +196,34 @@ class ChatStatusChecksTooltipContentNode: ASDisplayNode, TooltipControllerCustom
|
||||
self.deliveredChecksNode.updateState(false, animated: true)
|
||||
self.readChecksNode.updateState(false, animated: true)
|
||||
|
||||
self.deliveredChecksNode.layer.animateScale(from: 1.0, to: 1.12, duration: 0.25, delay: 0.1, removeOnCompletion: false, completion: { [weak self] _ in
|
||||
if let strongSelf = self {
|
||||
strongSelf.deliveredChecksNode.layer.animateScale(from: 1.12, to: 1.0, duration: 0.25)
|
||||
}
|
||||
})
|
||||
|
||||
self.deliveredTextNode.layer.animateScale(from: 1.0, to: 1.12, duration: 0.25, delay: 0.1, removeOnCompletion: false, completion: { [weak self] _ in
|
||||
if let strongSelf = self {
|
||||
strongSelf.deliveredTextNode.layer.animateScale(from: 1.12, to: 1.0, duration: 0.25)
|
||||
}
|
||||
})
|
||||
|
||||
Queue.mainQueue().after(0.5) {
|
||||
self.readChecksNode.updateState(true, animated: true)
|
||||
|
||||
self.readChecksNode.layer.animateScale(from: 1.0, to: 1.12, duration: 0.25, removeOnCompletion: false, completion: { [weak self] _ in
|
||||
Queue.mainQueue().after(0.25) {
|
||||
self.deliveredChecksNode.layer.animateScale(from: 1.0, to: 1.12, duration: 0.25, delay: 0.0, removeOnCompletion: false, completion: { [weak self] _ in
|
||||
if let strongSelf = self {
|
||||
strongSelf.readChecksNode.layer.animateScale(from: 1.12, to: 1.0, duration: 0.25)
|
||||
strongSelf.deliveredChecksNode.layer.animateScale(from: 1.12, to: 1.0, duration: 0.25)
|
||||
}
|
||||
})
|
||||
|
||||
self.readTextNode.layer.animateScale(from: 1.0, to: 1.12, duration: 0.25, removeOnCompletion: false, completion: { [weak self] _ in
|
||||
self.deliveredTextNode.layer.animateScale(from: 1.0, to: 1.12, duration: 0.25, delay: 0.0, removeOnCompletion: false, completion: { [weak self] _ in
|
||||
if let strongSelf = self {
|
||||
strongSelf.readTextNode.layer.animateScale(from: 1.12, to: 1.0, duration: 0.25)
|
||||
strongSelf.deliveredTextNode.layer.animateScale(from: 1.12, to: 1.0, duration: 0.25)
|
||||
}
|
||||
})
|
||||
|
||||
Queue.mainQueue().after(0.5) {
|
||||
self.readChecksNode.updateState(true, animated: true)
|
||||
|
||||
self.readChecksNode.layer.animateScale(from: 1.0, to: 1.12, duration: 0.25, removeOnCompletion: false, completion: { [weak self] _ in
|
||||
if let strongSelf = self {
|
||||
strongSelf.readChecksNode.layer.animateScale(from: 1.12, to: 1.0, duration: 0.25)
|
||||
}
|
||||
})
|
||||
|
||||
self.readTextNode.layer.animateScale(from: 1.0, to: 1.12, duration: 0.25, removeOnCompletion: false, completion: { [weak self] _ in
|
||||
if let strongSelf = self {
|
||||
strongSelf.readTextNode.layer.animateScale(from: 1.12, to: 1.0, duration: 0.25)
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user