Android Question UltimateWebView GeoLocation without ACCESS_BACKGROUND_LOCATION

Thiago Alves de Farias

Member
Licensed User
How can I use UltimateWebView with GeoLocation features, but without ACCESS_BACKGROUND_LOCATION permission ?

Here, when I don't ask permission for ACCESS_BACKGROUND_LOCATION the geolocation doesn't work.

Thanks!
 

drgottjr

Expert
Licensed User
Longtime User
if your app does not work without background location permission, ask for it.
you don't have to use it. google has it rules.

many apps are required to show broad permissions to features
the apps do not use. this shouldn't be a problem for you.

if you're trying to put an app with location services on play, then you will probably
have a problem no matter what you do.

i doubt the issue is with the ultimatewebview library. it's just following the rules.
 
Upvote 0

Thiago Alves de Farias

Member
Licensed User
Publishing to GooglePlay now requires me to explain why I'm asking for the ACCESS_BACKGROUND_LOCATION permission, and I have no arguments.
They even ask for a video that shows why I need it.
 
Upvote 0

drgottjr

Expert
Licensed User
Longtime User
as i just told you: trying to publish an app with location services on play is going to be a problem.

i don't mean to speak for the author of the ultimatewebviewlibrary, but access to background location is specifically mentioned in the library when some website wants to know your location. the user is then prompted to grant permission to the website permission. that's the rule. perhaps the author is away on holiday; i'm sure he'll see the thread soon. hang on until then.

a prompt for location permission is definitely required by a webview. usually coarse or fine access. if, in fact, background access permission does not have to be prompted for, i'm sure he can do something for you.

if google's code police have seen a reference to background location, i'm guessing it must be in the library. or maybe some other library you use. member golubovic should appear soon.
 
Upvote 0

Ivica Golubovic

Active Member
Licensed User
How can I use UltimateWebView with GeoLocation features, but without ACCESS_BACKGROUND_LOCATION permission ?

Here, when I don't ask permission for ACCESS_BACKGROUND_LOCATION the geolocation doesn't work.

Thanks!
Here I am after 10 days of working on one project. I am aware of the issues you are having with ACCESS_BACKGROUND_LOCATION. Basically, this permission is related to SDK29 and SDK30 and their Power Saver mode. The problem arises when the web source does not use the location within a few minutes. Then the system may turn off the location. Many web sources require that this permission be enabled to allow access to their geolocation server. I can remove this option but then you would have to define the permission for the background location by yourself. In any case, you will have a lot of trouble with geolocation and Google Play Store.
 
Upvote 0
Top