I am a newbie to android development.I am trying to put background
music for my app.I used intent service wherein  I declared media
player and from my main activity the service was called by explicit
intent.

Though the media player plays the music file but I am stuck with
following issues:-

1)I want to pause the music when the app has lost focus for eg. user
pressing back button to goto some previous app.But how do i pause the
media player which is inside a service.

I know that from my main activity's OnPause lifecycle method I should
make a call to pause the player.. but how do I achieve that?? Do I
have to bind the service to the activity or what should I do??

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to