I m creating an app, where I want to notify my app when phone's location changes in case app is not running in background or in killed state, how will broadcast receiver help me.Please help!
Thanks in advance.
I m creating an app, where I want to notify my app when phone's location changes in case app is not running in background or in killed state, how will broadcast receiver help me.Please help!
Thanks in advance.
*if you use googleApiClient and use onLocationChanged(Location location) override method then it automatically called after get new location, and this methods called every some time of seconds so don't depend if your device is really move from previous location so in onLocationChanged() you can do whatever you want of work like send notification to nitifi you but it bad because it will send you maybe every 5 sec or more new notification
*if you don't know how to get location even if app is killed you must create class that extends Service implements GoogleApiClient.ConnectionCallbacks, GoogleApiClient.OnConnectionFailedListener, LocationListener , and write it's methods
hope my answer is helpful , and if you wan't something till me