Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android Q support , Migrating legacystorage #310

Open
deepti1408 opened this issue Oct 11, 2020 · 4 comments
Open

Android Q support , Migrating legacystorage #310

deepti1408 opened this issue Oct 11, 2020 · 4 comments
Labels
android bug help-needed need help developing, using, testing this plugin

Comments

@deepti1408
Copy link

The plugin uses FileProvider.getUriForFile() whichis now nolonger supported fromAndroid Q scoped storage. Please release an update with new storage scope Mediastore api for android Q support

Android 10 and up

Pixel 2

Plugin version

cordova plugin version | grep cordova-plugin-file-opener2

Here is the output:
3.0.5

@cinnamon-doge
Copy link

cinnamon-doge commented May 5, 2021

I think we're running out of time regarding this issue, as Google chimes in on this:

We've detected that your app contains the requestLegacyExternalStorage flag in the manifest file of one or more of your app bundles or APKs.

Developers with apps on devices running Android 11+ must use scoped storage to give users better access control over their device storage. To release your app on Android 11 or newer after 5 May, you must either:

Update your app to use more privacy-friendly best practices, such as the storage access framework or Media Store API
Update your app to declare the All files access (MANAGE_EXTERNAL_STORAGE) permission in the manifest file, and complete the All files access permission declaration in Play Console from 5 May
Remove the All files access permission from your app entirely

For apps targeting Android 11, the requestLegacyExternalStorage flag will be ignored. You must use the All files access permission to retain broad access.

Apps requesting access to the All files access permission without a permitted use will be removed from Google Play, and you won't be able to publish updates.

@mharper6008
Copy link

It doesn't appear that this is something that is going to move forward.....or at least with any amount of timeliness. Has anyone taken an alternative approach to opening files in their default app?

@alex-steinberg
Copy link

@pwlin has there been any progress here? I'm happy to help but I'll need to be sent in the right direction as I'm not an Android dev.

@shnist shnist added bug help-needed need help developing, using, testing this plugin android labels Jan 31, 2023
@iamrakesh
Copy link

Using cordova-plugin-file implementation to get native URI for the file and using it for this plugin should work

#resolveLocalFileSystemURI() returns FileEntry, which has 'nativeURL' property, value of which can be used as parameter to this plugin's FileOpener2.open() method

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
android bug help-needed need help developing, using, testing this plugin
Projects
None yet
Development

No branches or pull requests

6 participants