mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-22 14:20:20 +00:00
Video avatar fixes
This commit is contained in:
@@ -635,6 +635,7 @@ public class AvatarGalleryController: ViewController, StandalonePresentableContr
|
||||
case let .progress(value):
|
||||
break
|
||||
case let .data(data):
|
||||
let screenImage: UIImage?
|
||||
let image: UIImage?
|
||||
let video: URL?
|
||||
if isImage {
|
||||
@@ -643,12 +644,14 @@ public class AvatarGalleryController: ViewController, StandalonePresentableContr
|
||||
} else {
|
||||
image = nil
|
||||
}
|
||||
screenImage = image
|
||||
video = nil
|
||||
} else {
|
||||
image = nil
|
||||
video = URL(fileURLWithPath: data.path)
|
||||
screenImage = nil
|
||||
}
|
||||
presentLegacyAvatarEditor(theme: strongSelf.presentationData.theme, image: image, video: video, present: { [weak self] c, a in
|
||||
presentLegacyAvatarEditor(theme: strongSelf.presentationData.theme, screenImage: screenImage, image: image, video: video, present: { [weak self] c, a in
|
||||
if let strongSelf = self {
|
||||
strongSelf.present(c, in: .window(.root), with: a, blockInteraction: true)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user