2

Now that FusedLocationProvider API is deprecated, I am using FusedLocationProviderClient, but I couldn't find how to detect when user turns the location off. Is there any listener for this?

Thank you in advance!

Andrei Pascale
  • 232
  • 1
  • 3
  • 16

1 Answers1

0

You can use https://developers.google.com/android/reference/com/google/android/gms/location/LocationCallback

wich expose

public void onLocationAvailability(LocationAvailability locationAvailability) 
Ghost
  • 340
  • 2
  • 9