mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-06-16 05:55:20 +00:00
Various fixes
This commit is contained in:
parent
dc0732ac4f
commit
451b9d92d1
@ -492,7 +492,7 @@ public final class ChatListSearchContainerNode: SearchDisplayControllerContentNo
|
||||
var options = options
|
||||
var tokens: [SearchBarToken] = []
|
||||
if self.groupId == .archive {
|
||||
tokens.append(SearchBarToken(id: ChatListTokenId.archive.rawValue, icon: UIImage(bundleImageName: "Chat List/Search/Archive"), title: self.presentationData.strings.ChatList_Archive, permanent: true))
|
||||
tokens.append(SearchBarToken(id: ChatListTokenId.archive.rawValue, icon: UIImage(bundleImageName: "Chat List/Search/Archive"), iconOffset: -1.0, title: self.presentationData.strings.ChatList_Archive, permanent: true))
|
||||
}
|
||||
|
||||
if options?.isEmpty ?? true {
|
||||
@ -566,7 +566,7 @@ public final class ChatListSearchContainerNode: SearchDisplayControllerContentNo
|
||||
|
||||
var tokens: [SearchBarToken] = []
|
||||
if self.groupId == .archive {
|
||||
tokens.append(SearchBarToken(id: ChatListTokenId.archive.rawValue, icon: UIImage(bundleImageName: "Chat List/Search/Archive"), title: self.presentationData.strings.ChatList_Archive, permanent: true))
|
||||
tokens.append(SearchBarToken(id: ChatListTokenId.archive.rawValue, icon: UIImage(bundleImageName: "Chat List/Search/Archive"), iconOffset: -1.0, title: self.presentationData.strings.ChatList_Archive, permanent: true))
|
||||
}
|
||||
self.setQuery?(nil, tokens, query ?? "")
|
||||
}
|
||||
|
@ -20,7 +20,7 @@ public protocol PeekControllerContent {
|
||||
func node() -> PeekControllerContentNode & ASDisplayNode
|
||||
|
||||
func topAccessoryNode() -> ASDisplayNode?
|
||||
func fullScreenAccessoryNode() -> (PeekControllerAccessoryNode & ASDisplayNode)?
|
||||
func fullScreenAccessoryNode(blurView: UIVisualEffectView) -> (PeekControllerAccessoryNode & ASDisplayNode)?
|
||||
|
||||
func isEqual(to: PeekControllerContent) -> Bool
|
||||
}
|
||||
|
@ -44,8 +44,10 @@ final class PeekControllerNode: ViewControllerTracingNode {
|
||||
self.controller = controller
|
||||
|
||||
self.dimNode = ASDisplayNode()
|
||||
self.blurView = UIVisualEffectView(effect: UIBlurEffect(style: self.theme.isDark ? .dark : .light))
|
||||
self.blurView.isUserInteractionEnabled = false
|
||||
|
||||
let blurView = UIVisualEffectView(effect: UIBlurEffect(style: self.theme.isDark ? .dark : .light))
|
||||
blurView.isUserInteractionEnabled = false
|
||||
self.blurView = blurView
|
||||
|
||||
self.darkDimNode = ASDisplayNode()
|
||||
self.darkDimNode.alpha = 0.0
|
||||
@ -70,7 +72,7 @@ final class PeekControllerNode: ViewControllerTracingNode {
|
||||
self.content = content
|
||||
self.contentNode = content.node()
|
||||
self.topAccessoryNode = content.topAccessoryNode()
|
||||
self.fullScreenAccessoryNode = content.fullScreenAccessoryNode()
|
||||
self.fullScreenAccessoryNode = content.fullScreenAccessoryNode(blurView: blurView)
|
||||
self.fullScreenAccessoryNode?.alpha = 0.0
|
||||
|
||||
var feedbackTapImpl: (() -> Void)?
|
||||
|
@ -41,7 +41,7 @@ final class StickerPreviewPeekContent: PeekControllerContent {
|
||||
return nil
|
||||
}
|
||||
|
||||
func fullScreenAccessoryNode() -> (PeekControllerAccessoryNode & ASDisplayNode)? {
|
||||
func fullScreenAccessoryNode(blurView: UIVisualEffectView) -> (PeekControllerAccessoryNode & ASDisplayNode)? {
|
||||
return nil
|
||||
}
|
||||
|
||||
|
@ -31,6 +31,7 @@ public final class PremiumStickersScreen: ViewController {
|
||||
private let containerNode: ASDisplayNode
|
||||
|
||||
private let textNode: ImmediateTextNode
|
||||
private let overlayTextNode: ImmediateTextNode
|
||||
private let proceedButton: SolidRoundedButtonNode
|
||||
private let cancelButton: HighlightableButtonNode
|
||||
private let carouselNode: ReactionCarouselNode
|
||||
@ -62,8 +63,12 @@ public final class PremiumStickersScreen: ViewController {
|
||||
self.textNode.textAlignment = .center
|
||||
self.textNode.maximumNumberOfLines = 0
|
||||
self.textNode.lineSpacing = 0.1
|
||||
self.textNode.attributedText = NSAttributedString(string: self.presentationData.strings.Premium_Reactions_Description, font: Font.regular(17.0), textColor: self.presentationData.theme.contextMenu.secondaryColor)
|
||||
self.textNode.alpha = 1.0
|
||||
|
||||
self.overlayTextNode = ImmediateTextNode()
|
||||
self.overlayTextNode.displaysAsynchronously = false
|
||||
self.overlayTextNode.textAlignment = .center
|
||||
self.overlayTextNode.maximumNumberOfLines = 0
|
||||
self.overlayTextNode.lineSpacing = 0.1
|
||||
|
||||
self.proceedButton = SolidRoundedButtonNode(title: self.presentationData.strings.Premium_Reactions_Proceed, icon: UIImage(bundleImageName: "Premium/ButtonIcon"), theme: SolidRoundedButtonTheme(theme: self.presentationData.theme), height: 50.0, cornerRadius: 11.0, gloss: true)
|
||||
|
||||
@ -73,7 +78,7 @@ public final class PremiumStickersScreen: ViewController {
|
||||
self.carouselNode = ReactionCarouselNode(context: controller.context, theme: controller.presentationData.theme, reactions: controller.reactions)
|
||||
|
||||
super.init()
|
||||
|
||||
|
||||
self.addSubnode(self.dimNode)
|
||||
self.addSubnode(self.darkDimNode)
|
||||
self.addSubnode(self.containerNode)
|
||||
@ -82,6 +87,17 @@ public final class PremiumStickersScreen: ViewController {
|
||||
self.containerNode.addSubnode(self.cancelButton)
|
||||
self.addSubnode(self.carouselNode)
|
||||
|
||||
let textColor: UIColor
|
||||
if self.presentationData.theme.overallDarkAppearance {
|
||||
textColor = UIColor(white: 1.0, alpha: 1.0)
|
||||
self.overlayTextNode.alpha = 0.2
|
||||
self.addSubnode(self.overlayTextNode)
|
||||
} else {
|
||||
textColor = self.presentationData.theme.contextMenu.secondaryColor
|
||||
}
|
||||
self.textNode.attributedText = NSAttributedString(string: self.presentationData.strings.Premium_Reactions_Description, font: Font.regular(17.0), textColor: textColor)
|
||||
self.overlayTextNode.attributedText = NSAttributedString(string: self.presentationData.strings.Premium_Reactions_Description, font: Font.regular(17.0), textColor: textColor)
|
||||
|
||||
self.proceedButton.pressed = { [weak self] in
|
||||
self?.animateOut()
|
||||
}
|
||||
@ -160,7 +176,10 @@ public final class PremiumStickersScreen: ViewController {
|
||||
self.proceedButton.frame = CGRect(origin: CGPoint(x: floorToScreenPixels((layout.size.width - buttonWidth) / 2.0), y: layout.size.height - cancelSize.height - 49.0 - buttonHeight - 23.0), size: CGSize(width: buttonWidth, height: buttonHeight))
|
||||
|
||||
let textSize = self.textNode.updateLayout(CGSize(width: layout.size.width - sideInset * 5.0, height: CGFloat.greatestFiniteMagnitude))
|
||||
self.textNode.frame = CGRect(origin: CGPoint(x: floorToScreenPixels((layout.size.width - textSize.width) / 2.0), y: layout.size.height - cancelSize.height - 48.0 - buttonHeight - 20.0 - textSize.height - 31.0), size: textSize)
|
||||
let _ = self.overlayTextNode.updateLayout(CGSize(width: layout.size.width - sideInset * 5.0, height: CGFloat.greatestFiniteMagnitude))
|
||||
let textFrame = CGRect(origin: CGPoint(x: floorToScreenPixels((layout.size.width - textSize.width) / 2.0), y: layout.size.height - cancelSize.height - 48.0 - buttonHeight - 20.0 - textSize.height - 31.0), size: textSize)
|
||||
self.textNode.frame = textFrame
|
||||
self.overlayTextNode.frame = textFrame
|
||||
}
|
||||
|
||||
|
||||
|
@ -335,7 +335,7 @@ public final class ReactionContextNode: ASDisplayNode, UIScrollViewDelegate {
|
||||
if case let .reaction(item) = self.items[i] {
|
||||
itemNode = ReactionNode(context: self.context, theme: self.theme, item: item)
|
||||
} else {
|
||||
itemNode = PremiumReactionsNode()
|
||||
itemNode = PremiumReactionsNode(theme: self.theme)
|
||||
}
|
||||
self.visibleItemNodes[i] = itemNode
|
||||
self.scrollNode.addSubnode(itemNode)
|
||||
|
@ -304,17 +304,22 @@ final class PremiumReactionsNode: ASDisplayNode, ReactionItemNode {
|
||||
|
||||
let imageNode: ASImageNode
|
||||
|
||||
override init() {
|
||||
init(theme: PresentationTheme) {
|
||||
self.imageNode = ASImageNode()
|
||||
self.imageNode.contentMode = .center
|
||||
self.imageNode.displaysAsynchronously = false
|
||||
self.imageNode.image = UIImage(bundleImageName: "Premium/ReactionIcon")
|
||||
self.imageNode.isUserInteractionEnabled = false
|
||||
self.imageNode.alpha = 0.5
|
||||
|
||||
super.init()
|
||||
|
||||
self.addSubnode(self.imageNode)
|
||||
|
||||
if theme.overallDarkAppearance {
|
||||
self.imageNode.image = generateTintedImage(image: UIImage(bundleImageName: "Premium/ReactionIcon"), color: .white)
|
||||
} else {
|
||||
self.imageNode.image = UIImage(bundleImageName: "Premium/ReactionIcon")
|
||||
}
|
||||
}
|
||||
|
||||
override func didLoad() {
|
||||
|
@ -41,13 +41,15 @@ public struct SearchBarToken {
|
||||
|
||||
public let id: AnyHashable
|
||||
public let icon: UIImage?
|
||||
public let iconOffset: CGFloat?
|
||||
public let title: String
|
||||
public let style: Style?
|
||||
public let permanent: Bool
|
||||
|
||||
public init(id: AnyHashable, icon: UIImage?, title: String, style: Style? = nil, permanent: Bool) {
|
||||
public init(id: AnyHashable, icon: UIImage?, iconOffset: CGFloat? = 0.0, title: String, style: Style? = nil, permanent: Bool) {
|
||||
self.id = id
|
||||
self.icon = icon
|
||||
self.iconOffset = iconOffset
|
||||
self.title = title
|
||||
self.style = style
|
||||
self.permanent = permanent
|
||||
@ -158,7 +160,11 @@ private final class TokenNode: ASDisplayNode {
|
||||
var leftInset: CGFloat = 3.0
|
||||
if let icon = self.iconNode.image {
|
||||
leftInset += 1.0
|
||||
transition.updateFrame(node: self.iconNode, frame: CGRect(origin: CGPoint(x: leftInset, y: floor((height - icon.size.height) / 2.0)), size: icon.size))
|
||||
var iconFrame = CGRect(origin: CGPoint(x: leftInset, y: floor((height - icon.size.height) / 2.0)), size: icon.size)
|
||||
if let iconOffset = self.token.iconOffset {
|
||||
iconFrame.origin.x += iconOffset
|
||||
}
|
||||
transition.updateFrame(node: self.iconNode, frame: iconFrame)
|
||||
leftInset += icon.size.width + 3.0
|
||||
}
|
||||
|
||||
|
@ -69,7 +69,7 @@ public final class StickerPreviewPeekContent: PeekControllerContent {
|
||||
return nil
|
||||
}
|
||||
|
||||
public func fullScreenAccessoryNode() -> (PeekControllerAccessoryNode & ASDisplayNode)? {
|
||||
public func fullScreenAccessoryNode(blurView: UIVisualEffectView) -> (PeekControllerAccessoryNode & ASDisplayNode)? {
|
||||
if self.isLocked {
|
||||
return PremiumStickerPackAccessoryNode(theme: self.theme, strings: self.strings)
|
||||
} else {
|
||||
@ -179,11 +179,12 @@ public final class StickerPreviewPeekContentNode: ASDisplayNode, PeekControllerC
|
||||
|
||||
let imageSize = dimensitons.cgSize.aspectFitted(boundingSize)
|
||||
self.imageNode.asyncLayout()(TransformImageArguments(corners: ImageCorners(), imageSize: imageSize, boundingSize: imageSize, intrinsicInsets: UIEdgeInsets()))()
|
||||
var imageFrame = CGRect(origin: CGPoint(x: 0.0, y: textSize.height + textSpacing), size: imageSize)
|
||||
var imageFrame = CGRect(origin: CGPoint(x: floor((size.width - imageSize.width) / 2.0), y: textSize.height + textSpacing), size: imageSize)
|
||||
var centerOffset: CGFloat = 0.0
|
||||
if self.item.file.isPremiumSticker {
|
||||
centerOffset = floor(imageFrame.width * 0.33)
|
||||
imageFrame = imageFrame.offsetBy(dx: centerOffset, dy: 0.0)
|
||||
let originalImageFrame = imageFrame
|
||||
imageFrame.origin.x = size.width - imageFrame.width - 10.0
|
||||
centerOffset = imageFrame.minX - originalImageFrame.minX
|
||||
}
|
||||
self.imageNode.frame = imageFrame
|
||||
if let animationNode = self.animationNode {
|
||||
@ -198,7 +199,7 @@ public final class StickerPreviewPeekContentNode: ASDisplayNode, PeekControllerC
|
||||
|
||||
self.textNode.frame = CGRect(origin: CGPoint(x: floor((imageFrame.size.width - textSize.width) / 2.0) - centerOffset, y: -textSize.height - textSpacing), size: textSize)
|
||||
|
||||
return CGSize(width: imageFrame.width, height: imageFrame.height + textSize.height + textSpacing)
|
||||
return CGSize(width: size.width, height: imageFrame.height + textSize.height + textSpacing)
|
||||
} else {
|
||||
return CGSize(width: size.width, height: 10.0)
|
||||
}
|
||||
@ -215,9 +216,8 @@ final class PremiumStickerPackAccessoryNode: ASDisplayNode, PeekControllerAccess
|
||||
self.textNode.displaysAsynchronously = false
|
||||
self.textNode.textAlignment = .center
|
||||
self.textNode.maximumNumberOfLines = 0
|
||||
self.textNode.attributedText = NSAttributedString(string: strings.Premium_Stickers_Description, font: Font.regular(17.0), textColor: .black)
|
||||
self.textNode.attributedText = NSAttributedString(string: strings.Premium_Stickers_Description, font: Font.regular(17.0), textColor: theme.actionSheet.secondaryTextColor)
|
||||
self.textNode.lineSpacing = 0.1
|
||||
self.textNode.alpha = 0.4
|
||||
|
||||
self.proceedButton = SolidRoundedButtonNode(title: strings.Premium_Stickers_Proceed, icon: UIImage(bundleImageName: "Premium/ButtonIcon"), theme: SolidRoundedButtonTheme(theme: theme), height: 50.0, cornerRadius: 11.0, gloss: true)
|
||||
|
||||
|
@ -228,6 +228,15 @@ private func setCachedAttachMenuBots(transaction: Transaction, attachMenuBots: A
|
||||
}
|
||||
}
|
||||
|
||||
private func removeCachedAttachMenuBot(postbox: Postbox, botId: PeerId) -> Signal<Void, NoError> {
|
||||
return postbox.transaction { transaction in
|
||||
if let bots = cachedAttachMenuBots(transaction: transaction) {
|
||||
let updatedBots = bots.bots.filter { $0.peerId != botId }
|
||||
setCachedAttachMenuBots(transaction: transaction, attachMenuBots: AttachMenuBots(hash: bots.hash, bots: updatedBots))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func managedSynchronizeAttachMenuBots(postbox: Postbox, network: Network, force: Bool = false) -> Signal<Void, NoError> {
|
||||
let poll = Signal<Void, NoError> { subscriber in
|
||||
let signal: Signal<Void, NoError> = cachedAttachMenuBots(postbox: postbox)
|
||||
@ -339,7 +348,7 @@ func _internal_addBotToAttachMenu(postbox: Postbox, network: Network, botId: Pee
|
||||
}
|
||||
|> mapToSignal { value -> Signal<Bool, AddBotToAttachMenuError> in
|
||||
if value {
|
||||
return managedSynchronizeAttachMenuBots(postbox: postbox, network: network)
|
||||
return managedSynchronizeAttachMenuBots(postbox: postbox, network: network, force: true)
|
||||
|> castError(AddBotToAttachMenuError.self)
|
||||
|> take(1)
|
||||
|> map { _ -> Bool in
|
||||
@ -372,8 +381,10 @@ func _internal_removeBotFromAttachMenu(postbox: Postbox, network: Network, botId
|
||||
return .single(false)
|
||||
}
|
||||
|> afterCompleted {
|
||||
let _ = (managedSynchronizeAttachMenuBots(postbox: postbox, network: network)
|
||||
|> take(1)).start()
|
||||
let _ = (managedSynchronizeAttachMenuBots(postbox: postbox, network: network, force: true)
|
||||
|> take(1)).start(completed: {
|
||||
let _ = removeCachedAttachMenuBot(postbox: postbox, botId: botId)
|
||||
})
|
||||
}
|
||||
}
|
||||
|> switchToLatest
|
||||
|
12
submodules/TelegramUI/Images.xcassets/Chat List/PremiumIcon.imageset/Contents.json
vendored
Normal file
12
submodules/TelegramUI/Images.xcassets/Chat List/PremiumIcon.imageset/Contents.json
vendored
Normal file
@ -0,0 +1,12 @@
|
||||
{
|
||||
"images" : [
|
||||
{
|
||||
"filename" : "premiumbadge_16.pdf",
|
||||
"idiom" : "universal"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"author" : "xcode",
|
||||
"version" : 1
|
||||
}
|
||||
}
|
240
submodules/TelegramUI/Images.xcassets/Chat List/PremiumIcon.imageset/premiumbadge_16.pdf
vendored
Normal file
240
submodules/TelegramUI/Images.xcassets/Chat List/PremiumIcon.imageset/premiumbadge_16.pdf
vendored
Normal file
@ -0,0 +1,240 @@
|
||||
%PDF-1.7
|
||||
|
||||
1 0 obj
|
||||
<< /Type /XObject
|
||||
/Length 2 0 R
|
||||
/Group << /Type /Group
|
||||
/S /Transparency
|
||||
>>
|
||||
/Subtype /Form
|
||||
/Resources << >>
|
||||
/BBox [ 0.000000 0.000000 16.000000 16.000000 ]
|
||||
>>
|
||||
stream
|
||||
/DeviceRGB CS
|
||||
/DeviceRGB cs
|
||||
q
|
||||
1.000000 0.000000 -0.000000 1.000000 -0.972168 3.548462 cm
|
||||
0.976471 0.631373 0.101961 scn
|
||||
8.051580 -0.065265 m
|
||||
8.386255 0.136172 8.553593 0.236891 8.732291 0.276237 c
|
||||
8.890351 0.311038 9.054091 0.311038 9.212152 0.276237 c
|
||||
9.390850 0.236891 9.558187 0.136172 9.892862 -0.065265 c
|
||||
10.895140 -0.668524 l
|
||||
12.034245 -1.354137 12.603798 -1.696944 13.007534 -1.631411 c
|
||||
13.357951 -1.574532 13.660391 -1.354298 13.822091 -1.038259 c
|
||||
14.008394 -0.674131 13.856972 -0.026846 13.554128 1.267724 c
|
||||
13.291615 2.389894 l
|
||||
13.202210 2.772070 13.157508 2.963159 13.175235 3.146049 c
|
||||
13.190914 3.307812 13.241741 3.464196 13.324162 3.604267 c
|
||||
13.417347 3.762632 13.565852 3.890926 13.862864 4.147514 c
|
||||
14.735314 4.901226 l
|
||||
15.744158 5.772767 16.248579 6.208537 16.311743 6.613088 c
|
||||
16.366564 6.964196 16.250860 7.320419 16.000189 7.572302 c
|
||||
15.711361 7.862525 15.047148 7.918721 13.718721 8.031113 c
|
||||
12.565221 8.128704 l
|
||||
12.175616 8.161667 11.980813 8.178148 11.812840 8.251106 c
|
||||
11.664268 8.315638 11.531527 8.411745 11.423840 8.532748 c
|
||||
11.302092 8.669552 11.225623 8.849475 11.072685 9.209321 c
|
||||
10.615263 10.285586 l
|
||||
10.098071 11.502484 9.839476 12.110933 9.475130 12.294894 c
|
||||
9.158871 12.454576 8.785572 12.454576 8.469313 12.294894 c
|
||||
8.104968 12.110933 7.846372 11.502483 7.329179 10.285583 c
|
||||
6.871758 9.209320 l
|
||||
6.718821 8.849475 6.642353 8.669552 6.520605 8.532748 c
|
||||
6.412918 8.411745 6.280177 8.315639 6.131604 8.251106 c
|
||||
5.963631 8.178148 5.768828 8.161667 5.379222 8.128704 c
|
||||
3.676359 7.984634 l
|
||||
2.812796 7.911572 2.381014 7.875041 2.157691 7.739972 c
|
||||
1.683759 7.453331 1.491831 6.862423 1.706876 6.352001 c
|
||||
1.808207 6.111484 2.136114 5.828204 2.791929 5.261645 c
|
||||
2.791929 5.261645 l
|
||||
3.063776 5.026796 3.199700 4.909371 3.347136 4.820806 c
|
||||
3.653106 4.637008 4.002688 4.538440 4.359606 4.535333 c
|
||||
4.531591 4.533835 4.708836 4.562960 5.063324 4.621209 c
|
||||
8.032967 5.109177 l
|
||||
8.951306 5.260077 9.410476 5.335527 9.519723 5.245213 c
|
||||
9.613404 5.167767 9.653514 5.042924 9.622472 4.925406 c
|
||||
9.586272 4.788361 9.169083 4.582251 8.334703 4.170029 c
|
||||
5.901720 2.968024 l
|
||||
5.497570 2.768355 5.295495 2.668521 5.126820 2.533812 c
|
||||
4.890324 2.344938 4.699779 2.104854 4.569541 1.831648 c
|
||||
4.476653 1.636790 4.425312 1.417324 4.322631 0.978392 c
|
||||
4.322631 0.978392 l
|
||||
4.077288 -0.070379 3.954616 -0.594764 4.064208 -0.903394 c
|
||||
4.218257 -1.337227 4.622936 -1.631910 5.083112 -1.645350 c
|
||||
5.410482 -1.654910 5.871894 -1.377192 6.794718 -0.821755 c
|
||||
8.051580 -0.065265 l
|
||||
h
|
||||
f*
|
||||
n
|
||||
Q
|
||||
q
|
||||
1.000000 0.000000 -0.000000 1.000000 -0.972168 3.548462 cm
|
||||
0.000000 0.000000 0.000000 scn
|
||||
8.051580 -0.065265 m
|
||||
8.386255 0.136172 8.553593 0.236891 8.732291 0.276237 c
|
||||
8.890351 0.311038 9.054091 0.311038 9.212152 0.276237 c
|
||||
9.390850 0.236891 9.558187 0.136172 9.892862 -0.065265 c
|
||||
10.895140 -0.668524 l
|
||||
12.034245 -1.354137 12.603798 -1.696944 13.007534 -1.631411 c
|
||||
13.357951 -1.574532 13.660391 -1.354298 13.822091 -1.038259 c
|
||||
14.008394 -0.674131 13.856972 -0.026846 13.554128 1.267724 c
|
||||
13.291615 2.389894 l
|
||||
13.202210 2.772070 13.157508 2.963159 13.175235 3.146049 c
|
||||
13.190914 3.307812 13.241741 3.464196 13.324162 3.604267 c
|
||||
13.417347 3.762632 13.565852 3.890926 13.862864 4.147514 c
|
||||
14.735314 4.901226 l
|
||||
15.744158 5.772767 16.248579 6.208537 16.311743 6.613088 c
|
||||
16.366564 6.964196 16.250860 7.320419 16.000189 7.572302 c
|
||||
15.711361 7.862525 15.047148 7.918721 13.718721 8.031113 c
|
||||
12.565221 8.128704 l
|
||||
12.175616 8.161667 11.980813 8.178148 11.812840 8.251106 c
|
||||
11.664268 8.315638 11.531527 8.411745 11.423840 8.532748 c
|
||||
11.302092 8.669552 11.225623 8.849475 11.072685 9.209321 c
|
||||
10.615263 10.285586 l
|
||||
10.098071 11.502484 9.839476 12.110933 9.475130 12.294894 c
|
||||
9.158871 12.454576 8.785572 12.454576 8.469313 12.294894 c
|
||||
8.104968 12.110933 7.846372 11.502483 7.329179 10.285583 c
|
||||
6.871758 9.209320 l
|
||||
6.718821 8.849475 6.642353 8.669552 6.520605 8.532748 c
|
||||
6.412918 8.411745 6.280177 8.315639 6.131604 8.251106 c
|
||||
5.963631 8.178148 5.768828 8.161667 5.379222 8.128704 c
|
||||
3.676359 7.984634 l
|
||||
2.812796 7.911572 2.381014 7.875041 2.157691 7.739972 c
|
||||
1.683759 7.453331 1.491831 6.862423 1.706876 6.352001 c
|
||||
1.808207 6.111484 2.136114 5.828204 2.791929 5.261645 c
|
||||
2.791929 5.261645 l
|
||||
3.063776 5.026796 3.199700 4.909371 3.347136 4.820806 c
|
||||
3.653106 4.637008 4.002688 4.538440 4.359606 4.535333 c
|
||||
4.531591 4.533835 4.708836 4.562960 5.063324 4.621209 c
|
||||
8.032967 5.109177 l
|
||||
8.951306 5.260077 9.410476 5.335527 9.519723 5.245213 c
|
||||
9.613404 5.167767 9.653514 5.042924 9.622472 4.925406 c
|
||||
9.586272 4.788361 9.169083 4.582251 8.334703 4.170029 c
|
||||
5.901720 2.968024 l
|
||||
5.497570 2.768355 5.295495 2.668521 5.126820 2.533812 c
|
||||
4.890324 2.344938 4.699779 2.104854 4.569541 1.831648 c
|
||||
4.476653 1.636790 4.425312 1.417324 4.322631 0.978392 c
|
||||
4.322631 0.978392 l
|
||||
4.077288 -0.070379 3.954616 -0.594764 4.064208 -0.903394 c
|
||||
4.218257 -1.337227 4.622936 -1.631910 5.083112 -1.645350 c
|
||||
5.410482 -1.654910 5.871894 -1.377192 6.794718 -0.821755 c
|
||||
8.051580 -0.065265 l
|
||||
h
|
||||
f*
|
||||
n
|
||||
Q
|
||||
|
||||
endstream
|
||||
endobj
|
||||
|
||||
2 0 obj
|
||||
4928
|
||||
endobj
|
||||
|
||||
3 0 obj
|
||||
<< /Type /XObject
|
||||
/Length 4 0 R
|
||||
/Group << /Type /Group
|
||||
/S /Transparency
|
||||
>>
|
||||
/Subtype /Form
|
||||
/Resources << >>
|
||||
/BBox [ 0.000000 0.000000 16.000000 16.000000 ]
|
||||
>>
|
||||
stream
|
||||
/DeviceRGB CS
|
||||
/DeviceRGB cs
|
||||
q
|
||||
1.000000 0.000000 -0.000000 1.000000 0.000000 0.000000 cm
|
||||
0.000000 0.000000 0.000000 scn
|
||||
0.000000 16.000000 m
|
||||
16.000000 16.000000 l
|
||||
16.000000 0.000000 l
|
||||
0.000000 0.000000 l
|
||||
0.000000 16.000000 l
|
||||
h
|
||||
f
|
||||
n
|
||||
Q
|
||||
|
||||
endstream
|
||||
endobj
|
||||
|
||||
4 0 obj
|
||||
232
|
||||
endobj
|
||||
|
||||
5 0 obj
|
||||
<< /XObject << /X1 1 0 R >>
|
||||
/ExtGState << /E1 << /SMask << /Type /Mask
|
||||
/G 3 0 R
|
||||
/S /Alpha
|
||||
>>
|
||||
/Type /ExtGState
|
||||
>> >>
|
||||
>>
|
||||
endobj
|
||||
|
||||
6 0 obj
|
||||
<< /Length 7 0 R >>
|
||||
stream
|
||||
/DeviceRGB CS
|
||||
/DeviceRGB cs
|
||||
q
|
||||
/E1 gs
|
||||
/X1 Do
|
||||
Q
|
||||
|
||||
endstream
|
||||
endobj
|
||||
|
||||
7 0 obj
|
||||
46
|
||||
endobj
|
||||
|
||||
8 0 obj
|
||||
<< /Annots []
|
||||
/Type /Page
|
||||
/MediaBox [ 0.000000 0.000000 16.000000 16.000000 ]
|
||||
/Resources 5 0 R
|
||||
/Contents 6 0 R
|
||||
/Parent 9 0 R
|
||||
>>
|
||||
endobj
|
||||
|
||||
9 0 obj
|
||||
<< /Kids [ 8 0 R ]
|
||||
/Count 1
|
||||
/Type /Pages
|
||||
>>
|
||||
endobj
|
||||
|
||||
10 0 obj
|
||||
<< /Pages 9 0 R
|
||||
/Type /Catalog
|
||||
>>
|
||||
endobj
|
||||
|
||||
xref
|
||||
0 11
|
||||
0000000000 65535 f
|
||||
0000000010 00000 n
|
||||
0000005186 00000 n
|
||||
0000005209 00000 n
|
||||
0000005689 00000 n
|
||||
0000005711 00000 n
|
||||
0000006009 00000 n
|
||||
0000006111 00000 n
|
||||
0000006132 00000 n
|
||||
0000006305 00000 n
|
||||
0000006379 00000 n
|
||||
trailer
|
||||
<< /ID [ (some) (id) ]
|
||||
/Root 10 0 R
|
||||
/Size 11
|
||||
>>
|
||||
startxref
|
||||
6439
|
||||
%%EOF
|
12
submodules/TelegramUI/Images.xcassets/Peer Info/PremiumIcon.imageset/Contents.json
vendored
Normal file
12
submodules/TelegramUI/Images.xcassets/Peer Info/PremiumIcon.imageset/Contents.json
vendored
Normal file
@ -0,0 +1,12 @@
|
||||
{
|
||||
"images" : [
|
||||
{
|
||||
"filename" : "premiumbadge_20.pdf",
|
||||
"idiom" : "universal"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"author" : "xcode",
|
||||
"version" : 1
|
||||
}
|
||||
}
|
97
submodules/TelegramUI/Images.xcassets/Peer Info/PremiumIcon.imageset/premiumbadge_20.pdf
vendored
Normal file
97
submodules/TelegramUI/Images.xcassets/Peer Info/PremiumIcon.imageset/premiumbadge_20.pdf
vendored
Normal file
@ -0,0 +1,97 @@
|
||||
%PDF-1.7
|
||||
|
||||
1 0 obj
|
||||
<< >>
|
||||
endobj
|
||||
|
||||
2 0 obj
|
||||
<< /Length 3 0 R >>
|
||||
stream
|
||||
/DeviceRGB CS
|
||||
/DeviceRGB cs
|
||||
q
|
||||
1.000000 0.000000 -0.000000 1.000000 1.312988 1.997192 cm
|
||||
0.000000 0.000000 0.000000 scn
|
||||
8.235496 2.764818 m
|
||||
4.319892 0.366102 l
|
||||
3.912743 0.116680 3.380487 0.244545 3.131065 0.651693 c
|
||||
3.009248 0.850546 2.972928 1.090177 3.030351 1.316196 c
|
||||
3.636486 3.701958 l
|
||||
3.855290 4.563177 4.444622 5.283089 5.245661 5.667681 c
|
||||
9.517389 7.718613 l
|
||||
9.716539 7.814228 9.800470 8.053183 9.704855 8.252333 c
|
||||
9.627422 8.413612 9.452311 8.503861 9.276028 8.473343 c
|
||||
4.521046 7.650135 l
|
||||
3.554468 7.482796 2.563253 7.749707 1.811401 8.379781 c
|
||||
0.309263 9.638615 l
|
||||
-0.056697 9.945299 -0.104749 10.490585 0.201936 10.856544 c
|
||||
0.351096 11.034534 0.565592 11.145033 0.797111 11.163151 c
|
||||
5.386590 11.522324 l
|
||||
5.710824 11.547698 5.993387 11.752888 6.117858 12.053352 c
|
||||
7.888392 16.327314 l
|
||||
8.071132 16.768436 8.576871 16.977896 9.017992 16.795156 c
|
||||
9.229803 16.707413 9.398088 16.539127 9.485833 16.327314 c
|
||||
11.256369 12.053352 l
|
||||
11.380839 11.752888 11.663401 11.547698 11.987636 11.522324 c
|
||||
16.602333 11.161178 l
|
||||
17.078350 11.123924 17.434040 10.707836 17.396788 10.231817 c
|
||||
17.378866 10.002825 17.270555 9.790377 17.095762 9.641360 c
|
||||
13.576328 6.640962 l
|
||||
13.328572 6.429744 13.220484 6.097248 13.296679 5.780720 c
|
||||
14.378658 1.285933 l
|
||||
14.490404 0.821718 14.204671 0.354813 13.740458 0.243067 c
|
||||
13.517399 0.189373 13.282146 0.226543 13.086508 0.346392 c
|
||||
9.138731 2.764818 l
|
||||
8.861588 2.934598 8.512639 2.934598 8.235496 2.764818 c
|
||||
h
|
||||
f*
|
||||
n
|
||||
Q
|
||||
|
||||
endstream
|
||||
endobj
|
||||
|
||||
3 0 obj
|
||||
1445
|
||||
endobj
|
||||
|
||||
4 0 obj
|
||||
<< /Annots []
|
||||
/Type /Page
|
||||
/MediaBox [ 0.000000 0.000000 20.000000 20.000000 ]
|
||||
/Resources 1 0 R
|
||||
/Contents 2 0 R
|
||||
/Parent 5 0 R
|
||||
>>
|
||||
endobj
|
||||
|
||||
5 0 obj
|
||||
<< /Kids [ 4 0 R ]
|
||||
/Count 1
|
||||
/Type /Pages
|
||||
>>
|
||||
endobj
|
||||
|
||||
6 0 obj
|
||||
<< /Pages 5 0 R
|
||||
/Type /Catalog
|
||||
>>
|
||||
endobj
|
||||
|
||||
xref
|
||||
0 7
|
||||
0000000000 65535 f
|
||||
0000000010 00000 n
|
||||
0000000034 00000 n
|
||||
0000001535 00000 n
|
||||
0000001558 00000 n
|
||||
0000001731 00000 n
|
||||
0000001805 00000 n
|
||||
trailer
|
||||
<< /ID [ (some) (id) ]
|
||||
/Root 6 0 R
|
||||
/Size 7
|
||||
>>
|
||||
startxref
|
||||
1864
|
||||
%%EOF
|
@ -47,7 +47,7 @@ final class ChatContextResultPeekContent: PeekControllerContent {
|
||||
return arrowNode
|
||||
}
|
||||
|
||||
func fullScreenAccessoryNode() -> (PeekControllerAccessoryNode & ASDisplayNode)? {
|
||||
func fullScreenAccessoryNode(blurView: UIVisualEffectView) -> (PeekControllerAccessoryNode & ASDisplayNode)? {
|
||||
return nil
|
||||
}
|
||||
|
||||
|
@ -431,6 +431,7 @@ class ChatControllerNode: ASDisplayNode, UIScrollViewDelegate {
|
||||
|
||||
self.historyNode.setLoadStateUpdated { [weak self] loadState, animated in
|
||||
if let strongSelf = self {
|
||||
let wasLoading = strongSelf.isLoadingValue
|
||||
if case .loading = loadState {
|
||||
strongSelf.updateIsLoading(isLoading: true, animated: animated)
|
||||
} else {
|
||||
@ -450,7 +451,7 @@ class ChatControllerNode: ASDisplayNode, UIScrollViewDelegate {
|
||||
} else if case .messages = loadState {
|
||||
strongSelf.didDisplayEmptyGreeting = true
|
||||
}
|
||||
strongSelf.updateIsEmpty(emptyType, animated: animated)
|
||||
strongSelf.updateIsEmpty(emptyType, wasLoading: wasLoading, animated: animated)
|
||||
}
|
||||
}
|
||||
|
||||
@ -646,7 +647,7 @@ class ChatControllerNode: ASDisplayNode, UIScrollViewDelegate {
|
||||
})
|
||||
}
|
||||
|
||||
private func updateIsEmpty(_ emptyType: ChatHistoryNodeLoadState.EmptyType?, animated: Bool) {
|
||||
private func updateIsEmpty(_ emptyType: ChatHistoryNodeLoadState.EmptyType?, wasLoading: Bool, animated: Bool) {
|
||||
self.emptyType = emptyType
|
||||
if let emptyType = emptyType, self.emptyNode == nil {
|
||||
let emptyNode = ChatEmptyNode(context: self.context, interaction: self.interfaceInteraction)
|
||||
|
Loading…
x
Reference in New Issue
Block a user