mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-04 05:26:48 +00:00
Update
This commit is contained in:
parent
54d2b58eb3
commit
5b65b52c61
@ -338,6 +338,8 @@ public class ChatTextInputPanelNode: ChatInputPanelNode, ASEditableTextNodeDeleg
|
||||
}
|
||||
}
|
||||
|
||||
public var ignoreInputStateUpdates: Bool = false
|
||||
|
||||
override public var context: AccountContext? {
|
||||
didSet {
|
||||
self.actionButtons.micButton.statusBarHost = self.context?.sharedContext.mainWindow?.statusBarHost
|
||||
@ -362,6 +364,10 @@ public class ChatTextInputPanelNode: ChatInputPanelNode, ASEditableTextNodeDeleg
|
||||
}
|
||||
|
||||
public func updateInputTextState(_ state: ChatTextInputState, keepSendButtonEnabled: Bool, extendedSearchLayout: Bool, accessoryItems: [ChatTextInputAccessoryItem], animated: Bool) {
|
||||
if self.ignoreInputStateUpdates {
|
||||
return
|
||||
}
|
||||
|
||||
if let currentState = self.presentationInterfaceState {
|
||||
var updateAccessoryButtons = false
|
||||
if accessoryItems.count == self.accessoryItemButtons.count {
|
||||
|
||||
@ -10190,6 +10190,8 @@ public final class ChatControllerImpl: TelegramBaseController, ChatController, G
|
||||
|
||||
var clearInputState = false
|
||||
if transferInputState {
|
||||
self.chatDisplayNode.textInputPanelNode?.ignoreInputStateUpdates = true
|
||||
|
||||
var peerId: PeerId
|
||||
var currentThreadId: Int64?
|
||||
switch self.chatLocation {
|
||||
@ -10294,6 +10296,8 @@ public final class ChatControllerImpl: TelegramBaseController, ChatController, G
|
||||
self.currentChatSwitchDirection = nil
|
||||
self.isUpdatingChatLocationThread = false
|
||||
|
||||
self.chatDisplayNode.textInputPanelNode?.ignoreInputStateUpdates = false
|
||||
|
||||
if clearInputState {
|
||||
//DispatchQueue.main.async { [weak self] in
|
||||
// guard let self else {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user