mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-08-08 08:31:13 +00:00
Merge commit '117a1f6c226bbc5a337c42d9f3d72286a890cdcf'
This commit is contained in:
commit
f81dab2f08
@ -1835,7 +1835,7 @@ public class ChatListControllerImpl: TelegramBaseController, ChatListController
|
||||
} else if let peerView = peerView, let channel = peerView.peers[peerView.peerId] as? TelegramChannel {
|
||||
switch channel.participationStatus {
|
||||
case .member:
|
||||
strongSelf.setToolbar(nil, transition: .animated(duration: 0.4, curve: .spring))
|
||||
toolbar = nil
|
||||
default:
|
||||
let actionTitle: String
|
||||
if channel.flags.contains(.requestToJoin) {
|
||||
@ -1843,13 +1843,13 @@ public class ChatListControllerImpl: TelegramBaseController, ChatListController
|
||||
} else {
|
||||
actionTitle = strongSelf.presentationData.strings.Channel_JoinChannel
|
||||
}
|
||||
strongSelf.setToolbar(Toolbar(leftAction: nil, rightAction: nil, middleAction: ToolbarAction(title: actionTitle, isEnabled: true)), transition: .animated(duration: 0.4, curve: .spring))
|
||||
toolbar = Toolbar(leftAction: nil, rightAction: nil, middleAction: ToolbarAction(title: actionTitle, isEnabled: true))
|
||||
}
|
||||
}
|
||||
var transition: ContainedViewLayoutTransition = .immediate
|
||||
let previousToolbar = previousToolbarValue.swap(toolbar)
|
||||
if (previousToolbar == nil) != (toolbar == nil) {
|
||||
transition = .animated(duration: 0.3, curve: .easeInOut)
|
||||
transition = .animated(duration: 0.4, curve: .spring)
|
||||
}
|
||||
strongSelf.setToolbar(toolbar, transition: transition)
|
||||
}))
|
||||
|
Loading…
x
Reference in New Issue
Block a user