Various Improvements

This commit is contained in:
Ilya Laktyushin
2022-01-18 20:52:09 +03:00
parent 3553b36394
commit 65918f2909
12 changed files with 527 additions and 61 deletions

View File

@@ -1979,11 +1979,11 @@ public final class ChatControllerImpl: TelegramBaseController, ChatController, G
}, openMessageShareMenu: { [weak self] id in
if let strongSelf = self, let messages = strongSelf.chatDisplayNode.historyNode.messageGroupInCurrentHistoryView(id), let _ = messages.first {
let shareController = ShareController(context: strongSelf.context, subject: .messages(messages), updatedPresentationData: strongSelf.updatedPresentationData, shareAsLink: true)
// shareController.openShareAsImage = { [weak self] messages in
// if let strongSelf = self {
// strongSelf.present(ChatQrCodeScreen(context: strongSelf.context, subject: .messages(messages)), in: .window(.root))
// }
// }
shareController.openShareAsImage = { [weak self] messages in
if let strongSelf = self {
strongSelf.present(ChatQrCodeScreen(context: strongSelf.context, subject: .messages(messages)), in: .window(.root))
}
}
shareController.dismissed = { [weak self] shared in
if shared {
self?.commitPurposefulAction()