0

How can I stop other apps that are playing background music when my app opens? I have an app that plays music and videos, but if a background app was already playing music it keeps playing.

On Fire TV I also have a problem that the background music app such as I heart Radio intercepts the play and forward buttons from the remote, so in my app if I try to skip forward it just switches I heart Radio to a new station and makes it start playing even if IhR had playback stopped.

The Netflix and Hulu apps both have solved it, so I know there has to be some way to do it, but my searching only turns up stuff on how to kill your own background service that is playing music, not any background music service.

I am trying to stick to API 8 for the greatest compatibility, but if I have to go up to a higher API I'd like to go no higher than 14 (ICS).

Wooble
  • 87,717
  • 12
  • 108
  • 131
Jon R. Helms
  • 52
  • 2
  • 8

1 Answers1

3

Per the FireTV documentation you need to manage Audio Focus via the requestAudioFocus call (added, as you need, in API8)

Offbeatmammal
  • 7,970
  • 2
  • 33
  • 52