Timo Drick
11/25/2022, 11:17 PMIntent.ACTION_OPEN_DOCUMENT_TREE
to let the user choose a directory and get access to this directory. It works but unfortunately the access is only temporary when the user closes the app and opens the app again i need to open the directory picker again. Especially for development this is very unpleasent. Of course i could ask the user for MANAGE_EXTERNAL_STORAGE permission but Google do not want this anymore for normal apps. My app is just a video player. But i need access to the directory to load subtitle files.Ian Lake
11/26/2022, 12:29 AMTimo Drick
11/26/2022, 12:48 AMIan Lake
11/26/2022, 12:49 AMTimo Drick
11/26/2022, 1:02 AMTimo Drick
11/26/2022, 1:03 AMval flags = Intent.FLAG_GRANT_READ_URI_PERMISSION
ctx.contentResolver.takePersistableUriPermission(uri, flags)
even if i do not care about reboots. But than it works when i restart the app.
Thank you very much