diff --git a/vector/src/main/java/im/vector/app/features/location/LocationSharingFragment.kt b/vector/src/main/java/im/vector/app/features/location/LocationSharingFragment.kt
index 12a84ac147..479ffd796d 100644
--- a/vector/src/main/java/im/vector/app/features/location/LocationSharingFragment.kt
+++ b/vector/src/main/java/im/vector/app/features/location/LocationSharingFragment.kt
@@ -209,14 +209,14 @@ class LocationSharingFragment @Inject constructor(
}
private fun tryStartLiveLocationSharing() {
- // TODO handle Android 11+ case => cannot ask runtime permission for background location
- // when ActivityCompat.shouldShowRequestPermissionRationale() returns true
- // show dialog to redirect to app settings (handleMissingBackgroundLocationPermission())
-
- // TODO test with Android 6, Android 10 and Android 11
// we need to re-check foreground location to be sure it has not changed after landing on this screen
if (checkPermissions(PERMISSIONS_FOR_FOREGROUND_LOCATION_SHARING, requireActivity(), foregroundLocationResultLauncher) &&
- checkPermissions(PERMISSIONS_FOR_BACKGROUND_LOCATION_SHARING, requireActivity(), backgroundLocationResultLauncher)) {
+ checkPermissions(
+ PERMISSIONS_FOR_BACKGROUND_LOCATION_SHARING,
+ requireActivity(),
+ backgroundLocationResultLauncher,
+ R.string.location_in_background_missing_permission_dialog_content
+ )) {
startLiveLocationSharing()
}
}
diff --git a/vector/src/main/res/values/strings.xml b/vector/src/main/res/values/strings.xml
index 9ec2cda85f..428be3209f 100644
--- a/vector/src/main/res/values/strings.xml
+++ b/vector/src/main/res/values/strings.xml
@@ -2938,7 +2938,7 @@
Share this location
Share this location
Allow access
- If you’d like to share your Live location, ${app_name} needs location access when the app is in the background.\nWe will only access your location for the duration that you choose.
+ If you’d like to share your Live location, ${app_name} needs location access all the time when the app is in the background.\nWe will only access your location for the duration that you choose.
${app_name} could not access your location
${app_name} could not access your location. Please try again later.
Open with