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
9d3f6d34c0
commit
4e4f479b57
@ -456,7 +456,7 @@ final class ChatItemGalleryFooterContentNode: GalleryFooterContentNode, UIScroll
|
|||||||
self.currentMessage = message
|
self.currentMessage = message
|
||||||
|
|
||||||
let canDelete: Bool
|
let canDelete: Bool
|
||||||
var canShare = !message.containsSecretMedia && !Namespaces.Message.allScheduled.contains(message.id.namespace)
|
var canShare = !message.containsSecretMedia
|
||||||
|
|
||||||
var canEdit = false
|
var canEdit = false
|
||||||
for media in message.media {
|
for media in message.media {
|
||||||
|
@ -218,6 +218,8 @@ public final class InviteLinkQRCodeController: ViewController {
|
|||||||
|
|
||||||
self.qrButtonNode = HighlightTrackingButtonNode()
|
self.qrButtonNode = HighlightTrackingButtonNode()
|
||||||
self.qrImageNode = TransformImageNode()
|
self.qrImageNode = TransformImageNode()
|
||||||
|
self.qrImageNode.clipsToBounds = true
|
||||||
|
self.qrImageNode.cornerRadius = 16.0
|
||||||
|
|
||||||
self.qrIconNode = AnimatedStickerNode()
|
self.qrIconNode = AnimatedStickerNode()
|
||||||
if let path = getAppBundle().path(forResource: "PlaneLogo", ofType: "tgs") {
|
if let path = getAppBundle().path(forResource: "PlaneLogo", ofType: "tgs") {
|
||||||
|
@ -1013,7 +1013,9 @@ final class ChatMediaInputNode: ChatInputNode {
|
|||||||
gallery.setHintWillBePresentedInPreviewingContext(true)
|
gallery.setHintWillBePresentedInPreviewingContext(true)
|
||||||
|
|
||||||
var items: [ContextMenuItem] = []
|
var items: [ContextMenuItem] = []
|
||||||
items.append(.action(ContextMenuActionItem(text: strongSelf.strings.MediaPicker_Send, icon: { _ in nil }, action: { _, f in
|
items.append(.action(ContextMenuActionItem(text: strongSelf.strings.MediaPicker_Send, icon: { theme in
|
||||||
|
return generateTintedImage(image: UIImage(bundleImageName: "Chat/Context Menu/Resend"), color: theme.actionSheet.primaryTextColor)
|
||||||
|
}, action: { _, f in
|
||||||
f(.default)
|
f(.default)
|
||||||
if isSaved {
|
if isSaved {
|
||||||
let _ = self?.controllerInteraction.sendGif(file.file, sourceNode, sourceRect)
|
let _ = self?.controllerInteraction.sendGif(file.file, sourceNode, sourceRect)
|
||||||
@ -1022,7 +1024,9 @@ final class ChatMediaInputNode: ChatInputNode {
|
|||||||
}
|
}
|
||||||
})))
|
})))
|
||||||
if isSaved || isGifSaved {
|
if isSaved || isGifSaved {
|
||||||
items.append(.action(ContextMenuActionItem(text: strongSelf.strings.Conversation_ContextMenuDelete, textColor: .destructive, icon: { _ in nil }, action: { _, f in
|
items.append(.action(ContextMenuActionItem(text: strongSelf.strings.Conversation_ContextMenuDelete, textColor: .destructive, icon: { theme in
|
||||||
|
return generateTintedImage(image: UIImage(bundleImageName: "Chat/Context Menu/Delete"), color: theme.actionSheet.destructiveActionTextColor)
|
||||||
|
}, action: { _, f in
|
||||||
f(.dismissWithoutContent)
|
f(.dismissWithoutContent)
|
||||||
|
|
||||||
guard let strongSelf = self else {
|
guard let strongSelf = self else {
|
||||||
@ -1031,7 +1035,9 @@ final class ChatMediaInputNode: ChatInputNode {
|
|||||||
let _ = removeSavedGif(postbox: strongSelf.context.account.postbox, mediaId: file.file.media.fileId).start()
|
let _ = removeSavedGif(postbox: strongSelf.context.account.postbox, mediaId: file.file.media.fileId).start()
|
||||||
})))
|
})))
|
||||||
} else if canSaveGif && !isGifSaved {
|
} else if canSaveGif && !isGifSaved {
|
||||||
items.append(.action(ContextMenuActionItem(text: strongSelf.strings.Preview_SaveGif, icon: { _ in nil }, action: { _, f in
|
items.append(.action(ContextMenuActionItem(text: strongSelf.strings.Preview_SaveGif, icon: { theme in
|
||||||
|
return generateTintedImage(image: UIImage(bundleImageName: "Chat/Context Menu/Save"), color: theme.actionSheet.primaryTextColor)
|
||||||
|
}, action: { _, f in
|
||||||
f(.dismissWithoutContent)
|
f(.dismissWithoutContent)
|
||||||
|
|
||||||
guard let strongSelf = self else {
|
guard let strongSelf = self else {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user