diff --git a/app/build.gradle b/app/build.gradle index eba887b67..0f3fcb483 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -46,7 +46,7 @@ ext { } dependencies { - implementation 'com.simplemobiletools:commons:3.13.0' + implementation 'com.simplemobiletools:commons:3.13.4' implementation 'com.theartofdev.edmodo:android-image-cropper:2.6.0' implementation 'com.android.support:multidex:1.0.2' implementation 'com.google.code.gson:gson:2.8.2' diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/EditActivity.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/EditActivity.kt index 54de2bfd5..37a17ae93 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/EditActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/EditActivity.kt @@ -204,7 +204,7 @@ class EditActivity : SimpleActivity(), CropImageView.OnCropImageCompleteListener Thread { val file = File(path) val fileDirItem = FileDirItem(path, path.getFilenameFromPath()) - getFileOutputStream(fileDirItem) { + getFileOutputStream(fileDirItem, true) { if (it != null) { saveBitmap(file, bitmap, it) } else { 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 c6b8469fd..3803f5b59 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt @@ -654,8 +654,9 @@ class MainActivity : SimpleActivity(), DirectoryAdapter.DirOperationsListener { } private fun checkLastMediaChanged() { - if (isActivityDestroyed()) + if (isActivityDestroyed()) { return + } mLastMediaHandler.removeCallbacksAndMessages(null) mLastMediaHandler.postDelayed({ diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/ViewPagerActivity.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/ViewPagerActivity.kt index 386737db0..605565680 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/ViewPagerActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/ViewPagerActivity.kt @@ -713,6 +713,7 @@ class ViewPagerActivity : SimpleActivity(), ViewPager.OnPageChangeListener, View if (requestCode == REQUEST_EDIT_IMAGE) { if (resultCode == Activity.RESULT_OK && resultData != null) { mPos = -1 + mPrevHashcode = 0 refreshViewPager() } } else if (requestCode == REQUEST_SET_AS) {