Open BorisLaskov opened 5 years ago
I've just realized that images that I pick through "Photos" are also stored locally... My point is: it simply works when I choose images from the default picker that appears first, but when I go to "Photos" through the drawer menu (where "Photos", Google Drive and potentially other apps reside) I encounter the bug described above. Sorry for confusion.
I am trying to select multiple images from the gallery.
It works fine for the files stored locally. Yet, when I choose Google Photos from the drawer menu, it allows me to select multiple pictures just fine but returns an array of just a single file.
I have done a little bit of debugging. I see that in
PickFiles.java
right in this place:it takes only a single
Uri
from.getData()
and proceeds without checkingClipData
(which is done in thegetUris(intent)
method). It looks like thisClipData
actually containsUri
s for all selected files including the first one, which is duplicated inside whatevergetData()
returns.If it allows me to select multiple images through GUI, I would expect it to return all of them instead of just one.
Tested on Nokia 7 plus and an emulator, both running Android 9.