mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-22 22:25:57 +00:00
Various improvements
This commit is contained in:
@@ -540,7 +540,7 @@ public func presentCustomNotificationSoundFilePicker(context: AccountContext, co
|
||||
let data = try Data(contentsOf: url)
|
||||
|
||||
if data.count > settings.maxSize {
|
||||
presentUndo(.info(title: presentationData.strings.Notifications_UploadError_TooLarge_Title, text: presentationData.strings.Notifications_UploadError_TooLarge_Text(dataSizeString(Int64(settings.maxSize), formatting: DataSizeStringFormatting(presentationData: presentationData))).string, timeout: nil))
|
||||
presentUndo(.info(title: presentationData.strings.Notifications_UploadError_TooLarge_Title, text: presentationData.strings.Notifications_UploadError_TooLarge_Text(dataSizeString(Int64(settings.maxSize), formatting: DataSizeStringFormatting(presentationData: presentationData))).string, timeout: nil, customUndoText: nil))
|
||||
|
||||
souceUrl.stopAccessingSecurityScopedResource()
|
||||
EngineTempBox.shared.dispose(tempFile)
|
||||
@@ -593,7 +593,7 @@ public func presentCustomNotificationSoundFilePicker(context: AccountContext, co
|
||||
if duration > Double(settings.maxDuration) {
|
||||
souceUrl.stopAccessingSecurityScopedResource()
|
||||
|
||||
presentUndo(.info(title: presentationData.strings.Notifications_UploadError_TooLong_Title(fileName).string, text: presentationData.strings.Notifications_UploadError_TooLong_Text(stringForDuration(Int32(settings.maxDuration))).string, timeout: nil))
|
||||
presentUndo(.info(title: presentationData.strings.Notifications_UploadError_TooLong_Title(fileName).string, text: presentationData.strings.Notifications_UploadError_TooLong_Text(stringForDuration(Int32(settings.maxDuration))).string, timeout: nil, customUndoText: nil))
|
||||
} else {
|
||||
Logger.shared.log("NotificationSoundSelection", "Uploading sound")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user