|
|
@ -100,10 +100,10 @@ object DocumentUtils { |
|
|
|
return listFiles(uri.path!!, filter) |
|
|
|
return listFiles(uri.path!!, filter) |
|
|
|
} |
|
|
|
} |
|
|
|
val docList = arrayListOf<FileDoc>() |
|
|
|
val docList = arrayListOf<FileDoc>() |
|
|
|
var cursor: Cursor? = null |
|
|
|
|
|
|
|
try { |
|
|
|
|
|
|
|
val childrenUri = DocumentsContract |
|
|
|
val childrenUri = DocumentsContract |
|
|
|
.buildChildDocumentsUriUsingTree(uri, DocumentsContract.getDocumentId(uri)) |
|
|
|
.buildChildDocumentsUriUsingTree(uri, DocumentsContract.getDocumentId(uri)) |
|
|
|
|
|
|
|
var cursor: Cursor? = null |
|
|
|
|
|
|
|
try { |
|
|
|
cursor = appCtx.contentResolver.query( |
|
|
|
cursor = appCtx.contentResolver.query( |
|
|
|
childrenUri, arrayOf( |
|
|
|
childrenUri, arrayOf( |
|
|
|
DocumentsContract.Document.COLUMN_DOCUMENT_ID, |
|
|
|
DocumentsContract.Document.COLUMN_DOCUMENT_ID, |
|
|
|