aboutsummaryrefslogtreecommitdiff
path: root/subsonic-android/src/github
diff options
context:
space:
mode:
authorScott Jackson <daneren2005@gmail.com>2013-01-05 08:54:15 -0800
committerScott Jackson <daneren2005@gmail.com>2013-01-05 08:54:15 -0800
commitd9aaeff16e83faa634fd46651ba550336788585b (patch)
tree266d10783699916baab2c55d7aa18e48e41ceeb0 /subsonic-android/src/github
parent42155771758951bf75b27581747577ff79c74c9e (diff)
downloaddsub-d9aaeff16e83faa634fd46651ba550336788585b.tar.gz
dsub-d9aaeff16e83faa634fd46651ba550336788585b.tar.bz2
dsub-d9aaeff16e83faa634fd46651ba550336788585b.zip
Fix requestAudioFocus not always running when starting playback
Diffstat (limited to 'subsonic-android/src/github')
-rw-r--r--subsonic-android/src/github/daneren2005/dsub/service/DownloadServiceImpl.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/subsonic-android/src/github/daneren2005/dsub/service/DownloadServiceImpl.java b/subsonic-android/src/github/daneren2005/dsub/service/DownloadServiceImpl.java
index 1878f422..68ae7a2f 100644
--- a/subsonic-android/src/github/daneren2005/dsub/service/DownloadServiceImpl.java
+++ b/subsonic-android/src/github/daneren2005/dsub/service/DownloadServiceImpl.java
@@ -727,9 +727,12 @@ public class DownloadServiceImpl extends Service implements DownloadService {
Util.broadcastPlaybackStatusChange(this, playerState);
this.playerState = playerState;
+
+ if(playerState == STARTED) {
+ Util.requestAudioFocus(this);
+ }
if (show) {
- Util.requestAudioFocus(this);
Util.showPlayingNotification(this, this, handler, currentPlaying.getSong());
} else if (hide) {
Util.hidePlayingNotification(this, this, handler);