diff --git a/submodules/TelegramCallsUI/Sources/PresentationGroupCall.swift b/submodules/TelegramCallsUI/Sources/PresentationGroupCall.swift index 4d39415150..3d12012574 100644 --- a/submodules/TelegramCallsUI/Sources/PresentationGroupCall.swift +++ b/submodules/TelegramCallsUI/Sources/PresentationGroupCall.swift @@ -864,9 +864,23 @@ public final class PresentationGroupCallImpl: PresentationGroupCall { if participant.peer.id == strongSelf.accountContext.account.peerId { if let muteState = participant.muteState { + if muteState.canUnmute { + switch strongSelf.isMutedValue { + case let .muted(isPushToTalkActive): + if !isPushToTalkActive { + strongSelf.callContext?.setIsMuted(true) + } + case .unmuted: + strongSelf.isMutedValue = .muted(isPushToTalkActive: false) + strongSelf.callContext?.setIsMuted(true) + } + } else { + strongSelf.isMutedValue = .muted(isPushToTalkActive: false) + strongSelf.callContext?.setIsMuted(true) + } strongSelf.stateValue.muteState = muteState - strongSelf.callContext?.setIsMuted(true) } else if let currentMuteState = strongSelf.stateValue.muteState, !currentMuteState.canUnmute { + strongSelf.isMutedValue = .muted(isPushToTalkActive: false) strongSelf.stateValue.muteState = GroupCallParticipantsContext.Participant.MuteState(canUnmute: true) strongSelf.callContext?.setIsMuted(true) } diff --git a/submodules/TgVoipWebrtc/tgcalls b/submodules/TgVoipWebrtc/tgcalls index 7c6b9e7e74..738dea0e50 160000 --- a/submodules/TgVoipWebrtc/tgcalls +++ b/submodules/TgVoipWebrtc/tgcalls @@ -1 +1 @@ -Subproject commit 7c6b9e7e74fd3f7197df7632d3f8170de1cb23f5 +Subproject commit 738dea0e5042e6d43b26f5425bcc07eafda3437f