stop loading fullscreen glide view on destroy

This commit is contained in:
tibbi 2019-05-13 23:58:47 +02:00
parent 8e798feaaa
commit 36dec5e004

View file

@ -21,6 +21,7 @@ import android.view.ViewGroup
import com.alexvasilkov.gestures.GestureController
import com.alexvasilkov.gestures.State
import com.bumptech.glide.Glide
import com.bumptech.glide.Priority
import com.bumptech.glide.load.DataSource
import com.bumptech.glide.load.DecodeFormat
import com.bumptech.glide.load.engine.DiskCacheStrategy
@ -228,6 +229,13 @@ class PhotoFragment : ViewPagerFragment() {
mView.subsampling_view.recycle()
}
try {
if (context != null) {
Glide.with(context!!).clear(mView.gestures_view)
}
} catch (ignored: Exception) {
}
mLoadZoomableViewHandler.removeCallbacksAndMessages(null)
if (mCurrentRotationDegrees != 0) {
Thread {