2
0
Fork 1
mirror of https://github.com/FossifyOrg/Gallery.git synced 2025-04-05 02:59:42 +02:00

improve the SAF file path selection

This commit is contained in:
tibbi 2018-10-22 10:37:36 +02:00
parent 552cb2ec5f
commit c05cad57d5

View file

@ -355,7 +355,7 @@ class MediaAdapter(activity: BaseSimpleActivity, var media: MutableList<Thumbnai
return
}
val SAFPath = getFirstSelectedItemPath() ?: return
val SAFPath = getSelectedPaths().firstOrNull { activity.isPathOnSD(it) } ?: getFirstSelectedItemPath() ?: return
activity.handleSAFDialog(SAFPath) {
val fileDirItems = ArrayList<FileDirItem>(selectedKeys.size)
val removeMedia = ArrayList<Medium>(selectedKeys.size)