mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-08-02 00:17:02 +00:00
Fix monoforum audio recording
This commit is contained in:
parent
e2bc739c7f
commit
8f7006281c
@ -366,7 +366,12 @@ extension ChatControllerImpl {
|
|||||||
let correlationId = Int64.random(in: 0 ..< Int64.max)
|
let correlationId = Int64.random(in: 0 ..< Int64.max)
|
||||||
var usedCorrelationId = false
|
var usedCorrelationId = false
|
||||||
|
|
||||||
if strongSelf.chatDisplayNode.shouldAnimateMessageTransition, let textInputPanelNode = strongSelf.chatDisplayNode.textInputPanelNode, let micButton = textInputPanelNode.micButton {
|
var shouldAnimateMessageTransition = strongSelf.chatDisplayNode.shouldAnimateMessageTransition
|
||||||
|
if strongSelf.chatLocation.threadId == nil, let channel = strongSelf.presentationInterfaceState.renderedPeer?.peer as? TelegramChannel, channel.isMonoForum, let linkedMonoforumId = channel.linkedMonoforumId, let mainChannel = strongSelf.presentationInterfaceState.renderedPeer?.peers[linkedMonoforumId] as? TelegramChannel, mainChannel.hasPermission(.sendSomething) {
|
||||||
|
shouldAnimateMessageTransition = false
|
||||||
|
}
|
||||||
|
|
||||||
|
if shouldAnimateMessageTransition, let textInputPanelNode = strongSelf.chatDisplayNode.textInputPanelNode, let micButton = textInputPanelNode.micButton {
|
||||||
usedCorrelationId = true
|
usedCorrelationId = true
|
||||||
strongSelf.chatDisplayNode.messageTransitionNode.add(correlationId: correlationId, source: .audioMicInput(ChatMessageTransitionNodeImpl.Source.AudioMicInput(micButton: micButton)), initiated: {
|
strongSelf.chatDisplayNode.messageTransitionNode.add(correlationId: correlationId, source: .audioMicInput(ChatMessageTransitionNodeImpl.Source.AudioMicInput(micButton: micButton)), initiated: {
|
||||||
guard let strongSelf = self else {
|
guard let strongSelf = self else {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user