mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2025-01-04 14:02:23 +01:00
Inform the user when the location provider is disabled.
This commit is contained in:
parent
7242f1c2f1
commit
db3f60b4b1
@ -83,6 +83,10 @@ class LocationTracker @Inject constructor(
|
||||
callback?.onLocationUpdate(location.toLocationData())
|
||||
}
|
||||
|
||||
override fun onProviderDisabled(provider: String) {
|
||||
callback?.onLocationProviderIsNotAvailable()
|
||||
}
|
||||
|
||||
private fun Location.toLocationData(): LocationData {
|
||||
return LocationData(latitude, longitude, accuracy.toDouble())
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user