(this is about the LocationManager class in android).
Is there a way of using requestLocationUpdates, but in some way that allows it to give me results for the best active provider every time? I could pass it the result of getBestProvider, but then it will always return results from that provider, and it wouldn’t work as I expect if the user turns the gps on/off.
My code is in a background service.
No, though you are welcome to register separate
LocationListenersfor multiple providers.Your
LocationListeneris notified when its provider is enabled and disabled. If your current provider is disabled, you might register aLocationListenerwith a backup provider.