-
-
Notifications
You must be signed in to change notification settings - Fork 111
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
fix(android/app): Update storage permissions for Android 12.0+ #11299
Conversation
User Test ResultsTest specification and instructions
Test Artifacts |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Can we not request permission to access the files at the time it is needed? I've certainly seen that before. I would expect:
- user selects file to open
- Keyman pops a message saying it'll need file/video/photo access in order to open the file
- User clicks OK, Keyman pops permission access request.
- User clicks Allow, Keyman installs the package.
I think on older versions of Android, it used to prompt for the permission when the file is accessed. That seems to have changed over the years. |
Test Results
|
Changes in this pull request will be available for download in Keyman version 17.0.314-beta |
Fixes #10659 and follows the permission refactoring from #10904
Reference
https://developer.android.com/about/versions/13/behavior-changes-13#granular-media-permissions
This updates CheckPermissions to ask for the corresponding storage permissions needed to install local kmp files.
For Android API 30-32
Manifest.permission.READ_EXTERNAL_STORAGE
For Android API 33+
Manifest.permission.READ_MEDIA_IMAGES
andManifest.permissions.READ_MEDIA_VIDEO
.(I tested without
READ_MEDIA_AUDIO
and it seemed to worked)Note:
For these devices, the user needs to still manually grant these permissions from Android Settings before Keyman can access local .kmp files. This is documented in the updated help page: grant-storage-permission.md
User Testing
Setup - Install the PR build of Keyman for Android on the corresponding Android device/emulator (API number in the test name)
Also, from Chrome, download a local copy of sil_ipa.kmp