aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorScott Jackson <daneren2005@gmail.com>2014-07-09 08:31:17 -0700
committerScott Jackson <daneren2005@gmail.com>2014-07-09 08:31:17 -0700
commita7ca15ba720681947dd3ed8507941e89db7c042a (patch)
tree1ebcdc50a2307f479a4c7b94c4fba1c054d7cecc /src
parent6a7aaafd33695307a2ac268642a967c1c9b45161 (diff)
downloaddsub-a7ca15ba720681947dd3ed8507941e89db7c042a.tar.gz
dsub-a7ca15ba720681947dd3ed8507941e89db7c042a.tar.bz2
dsub-a7ca15ba720681947dd3ed8507941e89db7c042a.zip
Only resume playing if still in PAUSED_TEMP state
If during the call, the audio_noisy broadcast is received, don't want to resume playing since it will then be in the PAUSED state.
Diffstat (limited to 'src')
-rw-r--r--src/github/daneren2005/dsub/service/DownloadServiceLifecycleSupport.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/github/daneren2005/dsub/service/DownloadServiceLifecycleSupport.java b/src/github/daneren2005/dsub/service/DownloadServiceLifecycleSupport.java
index 76c9abeb..18502846 100644
--- a/src/github/daneren2005/dsub/service/DownloadServiceLifecycleSupport.java
+++ b/src/github/daneren2005/dsub/service/DownloadServiceLifecycleSupport.java
@@ -332,7 +332,9 @@ public class DownloadServiceLifecycleSupport {
case TelephonyManager.CALL_STATE_IDLE:
if (resumeAfterCall) {
resumeAfterCall = false;
- downloadService.start();
+ if(downloadService.getPlayerState() == PlayerState.PAUSED_TEMP) {
+ downloadService.start();
+ }
}
break;
default: