Open cschulteksa opened 4 years ago
Consider adding an option to write to shared storage on Android 10 using a method similar to this:
ContentValues values = new ContentValues(); values.put(MediaStore.Images.Media.TITLE, timeStamp + ".jpg"); fileUri = getActivity().getContentResolver().insert(MediaStore.Images.Media.EXTERNAL_CONTENT_URI, values); ParcelFileDescriptor descriptor = getActivity().getContentResolver().openFileDescriptor(fileUri, "w"); FileOutputStream os = new FileOutputStream(descriptor.getFileDescriptor()); IOUtils.write(bytes, os);
Code is a little rough, but this works even with requestLegacyExternalStorage turned off on Android 10.
Wondering is this related to https://github.com/esafirm/android-image-picker/issues/380
Consider adding an option to write to shared storage on Android 10 using a method similar to this:
Code is a little rough, but this works even with requestLegacyExternalStorage turned off on Android 10.