android single-select image picker
-
12-11-2019 - |
Question
i'd like to use the gallery image picker to select a single image. i do something like,
Intent intent = new Intent(Intent.ACTION_PICK, Media.EXTERNAL_CONTENT_URI);
startActivityForResult(i, 0);
this works essentially, but if the user long-presses in the chooser, they enter multi select mode. first, i don't want them to select multiple images, but even if i did, they are stuck, because there's no way to "submit" the selection when in this mode.
i'd be happy if i could limit to single selection, or be able to get the multi-valued selection back correctly.
thanks.
No correct solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow