Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Alternate for googleMap.setOnMyLocationChangeListener since deprecated

Since googleMap.setOnMyLocationChangeListener is deprecated what is the best way for checking the my current location continuously?

I couldn't find any answer.

Any help much appreciated.

like image 463
Arnold Laishram Avatar asked Oct 19 '22 12:10

Arnold Laishram


1 Answers

In the documentation it is said:

use com.google.android.gms.location.FusedLocationProviderApi instead. FusedLocationProviderApi provides improved location finding and power usage and is used by the "My Location" blue dot. See the MyLocationDemoActivity in the sample applications folder for example example code, or the Location Developer Guide.

like image 142
Prokky Avatar answered Oct 21 '22 06:10

Prokky