mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-11-06 17:00:13 +00:00
Various fixes
This commit is contained in:
parent
975430aa85
commit
3532aad036
@ -14996,3 +14996,7 @@ Sorry for the inconvenience.";
|
|||||||
"Gift.Value.ForSaleOnFragment" = "for sale on Fragment";
|
"Gift.Value.ForSaleOnFragment" = "for sale on Fragment";
|
||||||
|
|
||||||
"Gift.View.Context.SetAsTheme" = "Set as Theme in...";
|
"Gift.View.Context.SetAsTheme" = "Set as Theme in...";
|
||||||
|
|
||||||
|
"Notification.PrepaidGiftUpgrade" = "Gift Upgrade for %@";
|
||||||
|
"Notification.PrepaidGiftUpgrade.Stars_1" = "%@ Star";
|
||||||
|
"Notification.PrepaidGiftUpgrade.Stars_any" = "%@ Stars";
|
||||||
|
|||||||
@ -1173,7 +1173,12 @@ public func universalServiceMessageString(presentationData: (PresentationTheme,
|
|||||||
let mutableAttributedString = NSMutableAttributedString(attributedString: stringWithAppliedEntities(text, entities: entities ?? [], baseColor: primaryTextColor, linkColor: primaryTextColor, baseFont: titleFont, linkFont: titleBoldFont, boldFont: titleBoldFont, italicFont: titleFont, boldItalicFont: titleBoldFont, fixedFont: titleFont, blockQuoteFont: titleFont, underlineLinks: false, message: message._asMessage()))
|
let mutableAttributedString = NSMutableAttributedString(attributedString: stringWithAppliedEntities(text, entities: entities ?? [], baseColor: primaryTextColor, linkColor: primaryTextColor, baseFont: titleFont, linkFont: titleBoldFont, boldFont: titleBoldFont, italicFont: titleFont, boldItalicFont: titleBoldFont, fixedFont: titleFont, blockQuoteFont: titleFont, underlineLinks: false, message: message._asMessage()))
|
||||||
attributedString = mutableAttributedString
|
attributedString = mutableAttributedString
|
||||||
} else {
|
} else {
|
||||||
attributedString = NSAttributedString(string: strings.Notification_Gift, font: titleFont, textColor: primaryTextColor)
|
if isPrepaidUpgrade {
|
||||||
|
let starsPrice = strings.Notification_PrepaidGiftUpgrade_Stars(Int32(clamping: upgradeStars ?? 0))
|
||||||
|
attributedString = NSAttributedString(string: strings.Notification_PrepaidGiftUpgrade(starsPrice).string, font: titleFont, textColor: primaryTextColor)
|
||||||
|
} else {
|
||||||
|
attributedString = NSAttributedString(string: strings.Notification_Gift, font: titleFont, textColor: primaryTextColor)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else if case let .generic(gift) = gift {
|
} else if case let .generic(gift) = gift {
|
||||||
var finalPrice = gift.price
|
var finalPrice = gift.price
|
||||||
|
|||||||
@ -5831,6 +5831,9 @@ public final class ChatControllerImpl: TelegramBaseController, ChatController, G
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
case .gift:
|
case .gift:
|
||||||
|
if let darkAppearancePreview = darkAppearancePreview {
|
||||||
|
useDarkAppearance = darkAppearancePreview
|
||||||
|
}
|
||||||
if let theme = makePresentationTheme(chatTheme: chatTheme, dark: useDarkAppearance) {
|
if let theme = makePresentationTheme(chatTheme: chatTheme, dark: useDarkAppearance) {
|
||||||
theme.forceSync = true
|
theme.forceSync = true
|
||||||
presentationData = presentationData.withUpdated(theme: theme).withUpdated(chatWallpaper: theme.chat.defaultWallpaper)
|
presentationData = presentationData.withUpdated(theme: theme).withUpdated(chatWallpaper: theme.chat.defaultWallpaper)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user