0

In my android app, parent activity launch a service on a user action using

bindService(intent, mConnection, Context.BIND_AUTO_CREATE);

In service I receive location updates(implementing LocationListener).

I also provide a STOP button on UI which enables user to kill the service.

unbindService(mConnection);

This action calls onDestroy() method of the service. What I observe is that even when I press STOP button(thus unbinding the service, and hence destroying it), onLocationChanged() is still getting called repeatedly.

How is it even possible when service has been unbinded, and destroyed?

Mandroid
  • 6,200
  • 12
  • 64
  • 134

0 Answers0