Prechádzať zdrojové kódy

reduce memory consumption of share extension by scaling down image thumbnail

cyberta 3 rokov pred
rodič
commit
bf2bb2c4e7
1 zmenil súbory, kde vykonal 1 pridanie a 1 odobranie
  1. 1 1
      DcShare/Helper/ShareAttachment.swift

+ 1 - 1
DcShare/Helper/ShareAttachment.swift

@@ -120,7 +120,7 @@ class ShareAttachment {
                 self.messages.append(msg)
                 self.delegate?.onAttachmentChanged()
                 if self.imageThumbnail == nil {
-                    self.imageThumbnail = result
+                    self.imageThumbnail = result.scaleDownImage(toMax: 96)
                     self.delegate?.onThumbnailChanged()
                 }
             }