From c7c8beba5b3bbd4f3924d87b2f6408a3eb20ec70 Mon Sep 17 00:00:00 2001 From: Isaac <> Date: Thu, 22 May 2025 02:42:33 +0800 Subject: [PATCH] Fix pinned animation --- .../Sources/Chat/ChatControllerLoadDisplayNode.swift | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/submodules/TelegramUI/Sources/Chat/ChatControllerLoadDisplayNode.swift b/submodules/TelegramUI/Sources/Chat/ChatControllerLoadDisplayNode.swift index 1e1f199a50..ff3a2ebd31 100644 --- a/submodules/TelegramUI/Sources/Chat/ChatControllerLoadDisplayNode.swift +++ b/submodules/TelegramUI/Sources/Chat/ChatControllerLoadDisplayNode.swift @@ -293,11 +293,14 @@ extension ChatControllerImpl { if self.presentationInterfaceState.search != nil && contentData.state.hasSearchTags { displayActionsPanel = true } - if displayActionsPanel != didDisplayActionsPanel { animated = true } + if previousState.pinnedMessage != contentData.state.pinnedMessage { + animated = true + } + self.updateChatPresentationInterfaceState(animated: animated && self.willAppear, interactive: false, { presentationInterfaceState in var presentationInterfaceState = presentationInterfaceState presentationInterfaceState = presentationInterfaceState.updatedPeer({ _ in