【发布时间】:2022-08-18 15:30:36
【问题描述】:
我们如何在 jetpack compose 的活动结果启动器中设置多个 mime 类型。
val documentPickerLauncher = rememberLauncherForActivityResult(contract = contracts,
onResult = {
// performing operations with selected file.
})
val scope = rememberCoroutineScope()
scope.launch {
// launching the file picker
launcher.launch(\"*/*\")
}
Here i can select all files in the storage. Instead of all files, i need to restrict this into png and pdf. How to acheive this?
标签: android android-jetpack-compose android-jetpack jetpack