Conference calls

This commit is contained in:
Isaac
2025-04-03 00:37:42 +04:00
parent 5deca3fac7
commit 1a31d83699
18 changed files with 380 additions and 136 deletions

View File

@@ -35,9 +35,15 @@ private func shareQrCode(context: AccountContext, link: String, ecl: String, vie
}
public final class QrCodeScreen: ViewController {
public enum SubjectType {
case group
case channel
case groupCall
}
public enum Subject {
case peer(peer: EnginePeer)
case invite(invite: ExportedInvitation, isGroup: Bool)
case invite(invite: ExportedInvitation, type: SubjectType)
case chatFolder(slug: String)
var link: String {
@@ -239,9 +245,17 @@ public final class QrCodeScreen: ViewController {
let title: String
let text: String
switch subject {
case let .invite(_, isGroup):
case let .invite(_, type):
title = self.presentationData.strings.InviteLink_QRCode_Title
text = isGroup ? self.presentationData.strings.InviteLink_QRCode_Info : self.presentationData.strings.InviteLink_QRCode_InfoChannel
switch type {
case .group:
text = self.presentationData.strings.InviteLink_QRCode_Info
case .channel:
text = self.presentationData.strings.InviteLink_QRCode_InfoChannel
case .groupCall:
//TODO:localize
text = "Everyone on Telegram can scan this code to join your group call."
}
case .chatFolder:
title = self.presentationData.strings.InviteLink_QRCodeFolder_Title
text = self.presentationData.strings.InviteLink_QRCodeFolder_Text