Merge commit '7621e2f8dec938cf48181c8b10afc9b01f444e68' into beta

This commit is contained in:
Ilya Laktyushin
2025-12-06 02:17:48 +04:00
commit 8344b97e03
28070 changed files with 7995182 additions and 0 deletions
@@ -0,0 +1,40 @@
import Foundation
import Display
import ChatControllerInteraction
import AccountContext
extension ChatControllerImpl {
func openLinkLongTap(_ action: ChatControllerInteractionLongTapAction, params: ChatControllerInteraction.LongTapParams?) {
if self.presentationInterfaceState.interfaceState.selectionState != nil {
return
}
self.dismissAllTooltips()
(self.view.window as? WindowHost)?.cancelInteractiveKeyboardGestures()
self.chatDisplayNode.cancelInteractiveKeyboardGestures()
self.chatDisplayNode.messageTransitionNode.dismissMessageReactionContexts()
guard let params else {
return
}
switch action {
case let .url(url):
self.openLinkContextMenu(url: url, params: params)
case let .mention(mention):
self.openMentionContextMenu(username: mention, peerId: nil, params: params)
case let .peerMention(peerId, mention):
self.openMentionContextMenu(username: mention, peerId: peerId, params: params)
case let .command(command):
self.openCommandContextMenu(command: command, params: params)
case let .hashtag(hashtag):
self.openHashtagContextMenu(hashtag: hashtag, params: params)
case let .timecode(value, timecode):
self.openTimecodeContextMenu(timecode: timecode, value: value, params: params)
case let .bankCard(number):
self.openBankCardContextMenu(number: number, params: params)
case let .phone(number):
self.openPhoneContextMenu(number: number, params: params)
}
}
}