removing a helper function related to moving path in recycle bin
This commit is contained in:
parent
ce4f9b02b7
commit
348d5617e0
2 changed files with 1 additions and 5 deletions
|
@ -935,7 +935,7 @@ class ViewPagerActivity : SimpleActivity(), ViewPager.OnPageChangeListener, View
|
|||
val path = getCurrentMedia().getOrNull(mPos)?.path ?: return
|
||||
val fileDirItem = FileDirItem(path, path.getFilenameFromPath())
|
||||
if (config.useRecycleBin && !getCurrentMedium()!!.getIsInRecycleBin()) {
|
||||
movePathInRecycleBin(path) {
|
||||
movePathsInRecycleBin(arrayListOf(path)) {
|
||||
if (it) {
|
||||
tryDeleteFileDirItem(fileDirItem, false, false) {
|
||||
refreshViewPager()
|
||||
|
|
|
@ -187,10 +187,6 @@ fun BaseSimpleActivity.tryDeleteFileDirItem(fileDirItem: FileDirItem, allowDelet
|
|||
}
|
||||
}
|
||||
|
||||
fun BaseSimpleActivity.movePathInRecycleBin(path: String, callback: ((wasSuccess: Boolean) -> Unit)?) {
|
||||
movePathsInRecycleBin(arrayListOf(path), callback)
|
||||
}
|
||||
|
||||
fun BaseSimpleActivity.movePathsInRecycleBin(paths: ArrayList<String>, callback: ((wasSuccess: Boolean) -> Unit)?) {
|
||||
Thread {
|
||||
var pathsCnt = paths.size
|
||||
|
|
Loading…
Reference in a new issue