updating Subsampling scale image view + null check

This commit is contained in:
tibbi 2020-04-14 22:49:05 +02:00
parent 9443fec381
commit c20f6fed0f
2 changed files with 5 additions and 1 deletions

View File

@ -92,7 +92,7 @@ dependencies {
implementation 'com.squareup.picasso:picasso:2.71828' implementation 'com.squareup.picasso:picasso:2.71828'
implementation 'com.caverock:androidsvg-aar:1.3' implementation 'com.caverock:androidsvg-aar:1.3'
implementation 'com.github.tibbi:gestureviews:512f929d82' implementation 'com.github.tibbi:gestureviews:512f929d82'
implementation 'com.github.tibbi:subsampling-scale-image-view:d404e74e39' implementation 'com.github.tibbi:subsampling-scale-image-view:381878c078'
kapt 'com.github.bumptech.glide:compiler:4.10.0' kapt 'com.github.bumptech.glide:compiler:4.10.0'

View File

@ -399,6 +399,10 @@ class PhotoFragment : ViewPagerFragment() {
options.diskCacheStrategy(DiskCacheStrategy.NONE) options.diskCacheStrategy(DiskCacheStrategy.NONE)
} }
if (context == null) {
return
}
Glide.with(context!!) Glide.with(context!!)
.load(getFilePathToShow()) .load(getFilePathToShow())
.apply(options) .apply(options)