Update submodules

This commit is contained in:
Peter
2019-04-16 19:37:11 +01:00
parent 02f95a726f
commit 06a69d4f81
5 changed files with 18 additions and 7 deletions

View File

@@ -335,12 +335,14 @@ class NotificationService: UNNotificationServiceExtension {
var inputFileLocation: (Int32, Api.InputFileLocation)?
var fetchResourceId: String?
var isPng = false
var isExpandableMedia = false
if let attachment = attachment {
switch attachment {
case let .photo(photo):
switch photo {
case let .photo(_, id, accessHash, fileReference, _, sizes, dcId):
isExpandableMedia = true
loop: for size in sizes {
switch size {
case let .photoSize(type, _, _, _, _):
@@ -368,6 +370,9 @@ class NotificationService: UNNotificationServiceExtension {
break
}
}
if isSticker {
isExpandableMedia = true
}
if let thumbs = thumbs {
loop: for size in thumbs {
switch size {
@@ -425,10 +430,12 @@ class NotificationService: UNNotificationServiceExtension {
userInfo["media"] = attachmentData.base64EncodedString()
if category == "r" {
self.bestAttemptContent?.categoryIdentifier = "withReplyMedia"
} else if category == "m" {
self.bestAttemptContent?.categoryIdentifier = "withMuteMedia"
if isExpandableMedia {
if category == "r" {
self.bestAttemptContent?.categoryIdentifier = "withReplyMedia"
} else if category == "m" {
self.bestAttemptContent?.categoryIdentifier = "withMuteMedia"
}
}
}
}

View File

@@ -4233,3 +4233,7 @@ Unused sets are archived when you add more.";
"ChatList.UnarchiveAction" = "Unarchive";
"ChatList.HideAction" = "Hide";
"ChatList.UnhideAction" = "Unhide";
"ChatList.UndoArchiveTitle" = "Chat Archived";
"ChatList.UndoArchiveText" = "Muted chats will stay archived after new messages arrive.";
"ChatList.ArchivedChatsTitle" = "Archived Chats";