mirror of
https://github.com/SimpleMobileTools/Simple-File-Manager.git
synced 2025-03-12 01:20:06 +01:00
some improvements to Copy
This commit is contained in:
parent
61946abbde
commit
035fde0a8f
@ -97,10 +97,13 @@ class CopyDialog(val activity: SimpleActivity, val files: ArrayList<File>, val c
|
|||||||
updatedFiles.add(destination)
|
updatedFiles.add(destination)
|
||||||
}
|
}
|
||||||
|
|
||||||
context.scanFiles(updatedFiles) {}
|
context.scanFiles(updatedFiles) {
|
||||||
context.toast(R.string.moving_success)
|
activity.runOnUiThread {
|
||||||
dismiss()
|
context.toast(R.string.moving_success)
|
||||||
copyMoveListener.copySucceeded(true, files.size * 2 == updatedFiles.size)
|
dismiss()
|
||||||
|
copyMoveListener.copySucceeded(true, files.size * 2 == updatedFiles.size)
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
@ -88,7 +88,9 @@ class ItemsFragment : android.support.v4.app.Fragment(), ItemsAdapter.ItemOperat
|
|||||||
setOnTouchListener { view, motionEvent -> checkDelete(); false }
|
setOnTouchListener { view, motionEvent -> checkDelete(); false }
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
val state = (items_list.layoutManager as LinearLayoutManager).onSaveInstanceState()
|
||||||
(currAdapter as ItemsAdapter).updateItems(mItems)
|
(currAdapter as ItemsAdapter).updateItems(mItems)
|
||||||
|
(items_list.layoutManager as LinearLayoutManager).onRestoreInstanceState(state)
|
||||||
}
|
}
|
||||||
|
|
||||||
getRecyclerLayoutManager().onRestoreInstanceState(arguments.getParcelable<Parcelable>(SCROLL_STATE))
|
getRecyclerLayoutManager().onRestoreInstanceState(arguments.getParcelable<Parcelable>(SCROLL_STATE))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user