diff --git a/app/build.gradle b/app/build.gradle index 6800312b8..5ce75a811 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -43,7 +43,7 @@ android { } dependencies { - implementation 'com.simplemobiletools:commons:4.8.4' + implementation 'com.simplemobiletools:commons:4.8.5' implementation 'com.theartofdev.edmodo:android-image-cropper:2.7.0' implementation 'com.android.support:multidex:1.0.3' implementation 'it.sephiroth.android.exif:library:1.0.1' 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 154c96a04..30ad07426 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt @@ -425,7 +425,8 @@ class MainActivity : SimpleActivity(), DirectoryOperationsListener { fileDirItems.isEmpty() -> return fileDirItems.size == 1 -> toast(String.format(getString(R.string.deleting_folder), fileDirItems.first().name)) else -> { - val deletingItems = resources.getQuantityString(R.plurals.deleting_items, fileDirItems.size, fileDirItems.size) + val baseString = if (config.useRecycleBin) R.plurals.moving_items_into_bin else R.plurals.delete_items + val deletingItems = resources.getQuantityString(baseString, fileDirItems.size, fileDirItems.size) toast(deletingItems) } } 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 5cb161a06..da83fef12 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MediaActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MediaActivity.kt @@ -837,10 +837,10 @@ class MediaActivity : SimpleActivity(), MediaOperationsListener { return } - val deletingItems = resources.getQuantityString(R.plurals.deleting_items, filtered.size, filtered.size) - toast(deletingItems) - if (config.useRecycleBin && !filtered.first().path.startsWith(filesDir.absolutePath)) { + val movingItems = resources.getQuantityString(R.plurals.moving_items_into_bin, filtered.size, filtered.size) + toast(movingItems) + movePathsInRecycleBin(filtered.map { it.path } as ArrayList, mMediumDao) { if (it) { deleteFilteredFiles(filtered) @@ -849,6 +849,8 @@ class MediaActivity : SimpleActivity(), MediaOperationsListener { } } } else { + val deletingItems = resources.getQuantityString(R.plurals.deleting_items, filtered.size, filtered.size) + toast(deletingItems) deleteFilteredFiles(filtered) } }