Fix crash in the image viewer (#1871)

This is imperfect as it probably reduces quality of the image but it
fixes the crash for now.
This commit is contained in:
Ivan Kupalov 2020-08-01 13:26:59 +02:00 committed by GitHub
parent 467c33aacb
commit be8fc9f15a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 0 deletions

View File

@ -205,6 +205,7 @@ class ViewImageFragment : ViewMediaFragment() {
.load(previewUrl)
.dontAnimate()
.onlyRetrieveFromCache(true)
.centerInside()
.addListener(ImageRequestListener(true, isThumnailRequest = true)))
else it
}
@ -213,6 +214,7 @@ class ViewImageFragment : ViewMediaFragment() {
.centerInside()
.addListener(ImageRequestListener(false, isThumnailRequest = false))
)
.centerInside()
.addListener(ImageRequestListener(true, isThumnailRequest = false))
.into(photoView)
}