You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Version Number of Plugin: 4.6.2.1
Device Tested On: Android emulator, base device: Pixel XL, Android 9.0, API 28
Simulator Tested On: Android emulator, base device: Pixel XL, Android 9.0, API 28
Version of VS: 16.4.3
Version of Xamarin: 16.4.000.308 (d16-4@4755fb3)
Versions of other things you are using:
Steps to reproduce the Behavior
Use await CrossGeolocator.Current.StartListeningAsync(), subscribe to events PositionChanged and PositionError.
When app is running, go to device location settings and disable location.
Expected Behavior
When location is disabled, event PositionError should be raised.
Actual Behavior
PositionError is not raised because passive provider is added to GeolocationContinuousListener
Code snippet
Fix:
In file GeolocatorImplementation.android.cs line 325 (just before listener = new GeolocationContinuousListener(Manager, minimumTime, providers);):
var providers = Providers;
replace with: var providers = Providers.Where(p => !IgnoredProviders.Contains(p)).ToArray();
The text was updated successfully, but these errors were encountered:
Bug Information
Version Number of Plugin: 4.6.2.1
Device Tested On: Android emulator, base device: Pixel XL, Android 9.0, API 28
Simulator Tested On: Android emulator, base device: Pixel XL, Android 9.0, API 28
Version of VS: 16.4.3
Version of Xamarin: 16.4.000.308 (d16-4@4755fb3)
Versions of other things you are using:
Steps to reproduce the Behavior
await CrossGeolocator.Current.StartListeningAsync()
, subscribe to events PositionChanged and PositionError.Expected Behavior
When location is disabled, event PositionError should be raised.
Actual Behavior
PositionError is not raised because passive provider is added to GeolocationContinuousListener
Code snippet
Fix:
In file GeolocatorImplementation.android.cs line 325 (just before
listener = new GeolocationContinuousListener(Manager, minimumTime, providers);
):var providers = Providers;
replace with:
var providers = Providers.Where(p => !IgnoredProviders.Contains(p)).ToArray();
The text was updated successfully, but these errors were encountered: