forked from shadowfacts/Tusker
Fix playing gifs from a background thread
This commit is contained in:
parent
4ac76ab672
commit
0a11d2de47
|
@ -165,7 +165,9 @@ class AttachmentView: UIImageView, GIFAnimatable {
|
|||
if self.attachment.url.pathExtension == "gif" {
|
||||
self.source = .gifData(attachmentURL, data)
|
||||
if self.autoplayGifs {
|
||||
self.animate(withGIFData: data)
|
||||
DispatchQueue.main.async {
|
||||
self.animate(withGIFData: data)
|
||||
}
|
||||
} else {
|
||||
self.displayImage()
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue