summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRicardo Cerqueira <ricardo@cyngn.com>2016-04-05 16:28:36 +0100
committerRicardo Cerqueira <ricardo@cyngn.com>2016-04-05 16:31:13 +0100
commitcfebddb4dea008982e8b20f1df63abfa4288d398 (patch)
tree78200e26261dfac9e4a2cc8529bc31493e3e895e
parentf9e74ef062907f14915e7ddf91286309a93d337f (diff)
downloadandroid_packages_apps_FMRadio-cfebddb4dea008982e8b20f1df63abfa4288d398.tar.gz
android_packages_apps_FMRadio-cfebddb4dea008982e8b20f1df63abfa4288d398.tar.bz2
android_packages_apps_FMRadio-cfebddb4dea008982e8b20f1df63abfa4288d398.zip
Fix incomplete app termination
When dismissing the task from the recents list, the app would go away but the service would stay up. Relaunching the app would then complete the termination and result in a second shutdown. Stop the service on task removal to avoid the weird double-start artifact. Ref CRACKLING-1025 Change-Id: I3bc3be75501294da4a526f0634149449f645edc2
-rw-r--r--src/com/android/fmradio/FmService.java1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/com/android/fmradio/FmService.java b/src/com/android/fmradio/FmService.java
index 553b6fa..4980c0b 100644
--- a/src/com/android/fmradio/FmService.java
+++ b/src/com/android/fmradio/FmService.java
@@ -2675,6 +2675,7 @@ public class FmService extends Service implements FmRecorder.OnRecorderStateChan
@Override
public void onTaskRemoved(Intent rootIntent) {
exitFm();
+ stopSelf();
super.onTaskRemoved(rootIntent);
}