From 638f4b4d45e6ec5b22894c01d84f5001a8228c99 Mon Sep 17 00:00:00 2001 From: tibbi Date: Mon, 27 Feb 2017 22:14:24 +0100 Subject: [PATCH] stop loading images on pause --- .../com/simplemobiletools/gallery/activities/MainActivity.kt | 2 ++ .../com/simplemobiletools/gallery/activities/MediaActivity.kt | 2 ++ 2 files changed, 4 insertions(+) diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt index 1a29c1a59..8d51574c3 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt @@ -102,6 +102,8 @@ class MainActivity : SimpleActivity(), DirectoryAdapter.DirOperationsListener { super.onPause() mCurrAsyncTask?.shouldStop = true storeDirectories() + directories_holder.isRefreshing = false + mIsGettingDirs = false } override fun onDestroy() { diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MediaActivity.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MediaActivity.kt index 107d77808..710eac8c5 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MediaActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MediaActivity.kt @@ -69,6 +69,8 @@ class MediaActivity : SimpleActivity(), MediaAdapter.MediaOperationsListener { override fun onPause() { super.onPause() mCurrAsyncTask?.shouldStop = true + mIsGettingMedia = false + media_holder.isRefreshing = false } private fun tryloadGallery() {