mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-07 14:53:35 +00:00
Fix build
This commit is contained in:
parent
700c915495
commit
934ed73331
@ -217,9 +217,9 @@ public enum DeviceMetrics: CaseIterable, Equatable {
|
|||||||
case .iPhone14Pro, .iPhone14ProMax:
|
case .iPhone14Pro, .iPhone14ProMax:
|
||||||
return 55.0
|
return 55.0
|
||||||
case .iPhone16Pro, .iPhone16ProMax:
|
case .iPhone16Pro, .iPhone16ProMax:
|
||||||
return 55.0
|
return 62.0
|
||||||
case .iPhoneAir:
|
case .iPhoneAir:
|
||||||
return 55.0
|
return 62.0
|
||||||
case let .unknown(_, _, _, screenCornerRadius):
|
case let .unknown(_, _, _, screenCornerRadius):
|
||||||
return screenCornerRadius
|
return screenCornerRadius
|
||||||
default:
|
default:
|
||||||
|
|||||||
@ -394,7 +394,7 @@ public extension Peer {
|
|||||||
|
|
||||||
public extension TelegramPeerUsername {
|
public extension TelegramPeerUsername {
|
||||||
var isActive: Bool {
|
var isActive: Bool {
|
||||||
return self.flags.contains(.isActive) || self.flags.contains(.isEditable)
|
return self.flags.contains(.isActive)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -768,7 +768,8 @@ final class UserAppearanceScreenComponent: Component {
|
|||||||
valueCurrency: nil,
|
valueCurrency: nil,
|
||||||
flags: [],
|
flags: [],
|
||||||
themePeerId: nil,
|
themePeerId: nil,
|
||||||
peerColor: nil
|
peerColor: nil,
|
||||||
|
hostPeerId: nil
|
||||||
)
|
)
|
||||||
signal = component.context.engine.accountData.setStarGiftStatus(starGift: gift, expirationDate: emojiStatus.expirationDate)
|
signal = component.context.engine.accountData.setStarGiftStatus(starGift: gift, expirationDate: emojiStatus.expirationDate)
|
||||||
} else {
|
} else {
|
||||||
@ -1110,7 +1111,16 @@ final class UserAppearanceScreenComponent: Component {
|
|||||||
let updatedSection = Section(rawValue: intValue) ?? .profile
|
let updatedSection = Section(rawValue: intValue) ?? .profile
|
||||||
if self.currentSection != updatedSection {
|
if self.currentSection != updatedSection {
|
||||||
if (updatedSection == .name && self.selectedProfileGift != nil) || (updatedSection == .profile && self.selectedNameGift != nil) {
|
if (updatedSection == .name && self.selectedProfileGift != nil) || (updatedSection == .profile && self.selectedNameGift != nil) {
|
||||||
|
switch updatedSection {
|
||||||
|
case .profile:
|
||||||
|
self.selectedNameGift = nil
|
||||||
|
self.updatedPeerNameColor = nil
|
||||||
|
self.updatedPeerNameEmoji = nil
|
||||||
|
case .name:
|
||||||
|
self.selectedProfileGift = nil
|
||||||
|
self.updatedPeerProfileColor = nil
|
||||||
|
self.updatedPeerProfileEmoji = nil
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
self.currentSection = updatedSection
|
self.currentSection = updatedSection
|
||||||
self.state?.updated(transition: .easeInOut(duration: 0.3).withUserData(TransitionHint(animateTabChange: true)))
|
self.state?.updated(transition: .easeInOut(duration: 0.3).withUserData(TransitionHint(animateTabChange: true)))
|
||||||
@ -1871,6 +1881,8 @@ public class UserAppearanceScreen: ViewControllerComponentContainer {
|
|||||||
|
|
||||||
self.automaticallyControlPresentationContextLayout = false
|
self.automaticallyControlPresentationContextLayout = false
|
||||||
|
|
||||||
|
self.supportedOrientations = ViewControllerSupportedOrientations(regularSize: .all, compactSize: .portrait)
|
||||||
|
|
||||||
let presentationData = context.sharedContext.currentPresentationData.with { $0 }
|
let presentationData = context.sharedContext.currentPresentationData.with { $0 }
|
||||||
self.title = ""
|
self.title = ""
|
||||||
self.navigationItem.backBarButtonItem = UIBarButtonItem(title: presentationData.strings.Common_Back, style: .plain, target: nil, action: nil)
|
self.navigationItem.backBarButtonItem = UIBarButtonItem(title: presentationData.strings.Common_Back, style: .plain, target: nil, action: nil)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user