Skip to content
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

Significant location updates don't always stop after StopListeningAsync (iOS) #5

Closed
2 of 13 tasks
jamesmontemagno opened this issue Jun 29, 2016 · 0 comments
Closed
2 of 13 tasks

Comments

@jamesmontemagno
Copy link
Owner

From @kgerken on April 15, 2016 16:37

This is a

  • Bug
  • Feature Request

Which plugin does this impact:

  • Battery
  • Connectivity
  • Contacts
  • DeviceInfo
  • ExternalMaps
  • Geolocator
  • Media
  • Permissions
  • Settings
  • Text To Speech
  • Vibrate
  • Other:

StopListeningAsync does not always stop the location monitoring if the geolocator was started with significant location changes (SLC). SLC wakes the app periodically and even restarts it after a device reboot. In those cases, IsListening in GeolocatorImplementation might no longer be true, so StopListeningAsync immediately returns.

CLLocationManager does not seem to provide a property to check for the current listening status, yet it appears to be save to call stopMonitoringSignificantLocationChanges on CLLocationManager even when the manager is not currently monitoring. But even if the check for IsListening was removed from StopListeningAsync, we would still need to know whether we should stop the "normal" location updates or SLC, so maybe the ListenerSettings need to be passed into StopListeningAsync as well?

Copied from original issue: jamesmontemagno/Xamarin.Plugins#284

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant