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 return
} }
val SAFPath = getFirstSelectedItemPath() ?: return val SAFPath = getSelectedPaths().firstOrNull { activity.isPathOnSD(it) } ?: getFirstSelectedItemPath() ?: return
activity.handleSAFDialog(SAFPath) { activity.handleSAFDialog(SAFPath) {
val fileDirItems = ArrayList<FileDirItem>(selectedKeys.size) val fileDirItems = ArrayList<FileDirItem>(selectedKeys.size)
val removeMedia = ArrayList<Medium>(selectedKeys.size) val removeMedia = ArrayList<Medium>(selectedKeys.size)