[TIMOB-28049] Android: Investigate "ACCESS_BACKGROUND_LOCATION" handling on Android 11
GitHub Issue | n/a |
---|---|
Type | Story |
Priority | High |
Status | Closed |
Resolution | Done |
Resolution Date | 2020-09-19T06:09:32.000+0000 |
Affected Version/s | n/a |
Fix Version/s | Release 9.3.0 |
Components | Android |
Labels | android, location, permission |
Reporter | Joshua Quick |
Assignee | Joshua Quick |
Created | 2020-07-25T01:20:26.000+0000 |
Updated | 2020-11-03T15:22:08.000+0000 |
Description
*Summary:* Supposedly, Android 11 will no longer show a permission request dialog for theACCESS_BACKGROUND_LOCATION
permission. We need to confirm this.
https://developer.android.com/preview/privacy/location#background-location-permission-dialog-changes
If true, then the only way to enable permission is to go to the app's "Location Permissions" activity under system settings. This very well maybe true because according to Google's developer blog below, they will be removing apps using this permission from Google Play unless they provide a valid reason and pass Google's review process.
https://android-developers.googleblog.com/2020/02/safer-location-access.html
*Note 1:*
We might be able to reach the app's "Location Permission" activity under system settings via the following intent action.
ACTION_LOCATION_SOURCE_SETTINGS
*Note 2:*
We may need to expose Android's [shouldShowRequestPermissionRationale ()](https://developer.android.com/reference/android/app/Activity.html#shouldShowRequestPermissionRationale(java.lang.String)) API. Normally, this method would return true
if the end-user tapped on "Disallow" in the permission request dialog. On Android 11, this might always return true
for the ACCESS_BACKGROUND_LOCATION
where you would have to tell the end-user how to enable it under system settings.
Attachments
File | Date | Size |
---|---|---|
Android11-AllLocationPermissions.png | 2020-09-05T03:35:01.000+0000 | 171003 |
Android11-BackgroundLocationPermission.png | 2020-09-05T03:35:01.000+0000 | 166667 |
GeolocationGpsService.js | 2020-09-11T00:32:13.000+0000 | 419 |
GeolocationGpsTest.js | 2020-09-11T00:32:14.000+0000 | 5482 |
tiapp.xml | 2020-09-11T00:32:14.000+0000 | 1083 |