mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-22 14:20:20 +00:00
Merge commit 'eb28692e92f2375bd911d63eeb35ed8468296fda'
# Conflicts: # submodules/TelegramUI/Components/Stories/StoryContainerScreen/Sources/StoryItemSetContainerComponent.swift
This commit is contained in:
@@ -10966,15 +10966,15 @@ public final class ChatControllerImpl: TelegramBaseController, ChatController, G
|
||||
}
|
||||
}
|
||||
|
||||
self.volumeButtonsListener = VolumeButtonsListener(shouldBeActive: shouldBeActive, valueChanged: { [weak self] in
|
||||
guard let strongSelf = self, strongSelf.traceVisibility() && isTopmostChatController(strongSelf) else {
|
||||
let buttonAction = { [weak self] in
|
||||
guard let self, self.traceVisibility() && isTopmostChatController(self) else {
|
||||
return
|
||||
}
|
||||
strongSelf.videoUnmuteTooltipController?.dismiss()
|
||||
self.videoUnmuteTooltipController?.dismiss()
|
||||
|
||||
var actions: [(Bool, (Double?) -> Void)] = []
|
||||
var hasUnconsumed = false
|
||||
strongSelf.chatDisplayNode.historyNode.forEachVisibleItemNode { itemNode in
|
||||
self.chatDisplayNode.historyNode.forEachVisibleItemNode { itemNode in
|
||||
if let itemNode = itemNode as? ChatMessageItemView, let (action, _, _, isUnconsumed, _) = itemNode.playMediaWithSound() {
|
||||
if case let .visible(fraction, _) = itemNode.visibility, fraction > 0.7 {
|
||||
actions.insert((isUnconsumed, action), at: 0)
|
||||
@@ -10990,7 +10990,12 @@ public final class ChatControllerImpl: TelegramBaseController, ChatController, G
|
||||
break
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
self.volumeButtonsListener = VolumeButtonsListener(
|
||||
shouldBeActive: shouldBeActive,
|
||||
upPressed: buttonAction,
|
||||
downPressed: buttonAction
|
||||
)
|
||||
|
||||
self.chatDisplayNode.historyNode.openNextChannelToRead = { [weak self] peer, location in
|
||||
guard let strongSelf = self else {
|
||||
|
||||
Reference in New Issue
Block a user