Change FM off button to release media and audio resources.

When FM application is launched, no other Media consuming
application can receive key events (play, pause etc.) because
FM service is the owner of MediaSession and AudioFocus. This
does not bode well for user experience. Change the behaviour
of FM off button so that we release MediaSession and AudioFocus
so that other applications can work.
The same behaviour is enabled when antenna is pulled out.

We differentiate FM off from remote bluetooth headset
start/stop i.e. when remote headset does start/stop, it starts/stops
FM. This means that if user presses FM off button, user has to
explicitly turn it on again.

Also remove old FM Media Button Intent receiver as it is deprecated.

CRs-Fixed: 936190
Change-Id: I32fef8e43b226a260d5483b40f5825926c023e62
3 files changed
tree: cb6420d6b84ada2c88a10204cd939b6e18a0540a
  1. fmapp/
  2. fmapp2/
  3. FMRecord/
  4. jni/
  5. libfm_jni/
  6. qcom/
  7. Android.mk