Stop service on status change
This commit is contained in:
parent
632906df07
commit
c2ace74156
|
@ -677,11 +677,6 @@ public class PlaybackService extends MediaBrowserServiceCompat {
|
||||||
writePlayerStatusPlaybackPreferences();
|
writePlayerStatusPlaybackPreferences();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case STOPPED:
|
|
||||||
//setCurrentlyPlayingMedia(PlaybackPreferences.NO_MEDIA_PLAYING);
|
|
||||||
//stopSelf();
|
|
||||||
break;
|
|
||||||
|
|
||||||
case PLAYING:
|
case PLAYING:
|
||||||
writePlayerStatusPlaybackPreferences();
|
writePlayerStatusPlaybackPreferences();
|
||||||
setupNotification(newInfo);
|
setupNotification(newInfo);
|
||||||
|
@ -694,8 +689,9 @@ public class PlaybackService extends MediaBrowserServiceCompat {
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ERROR:
|
case ERROR: case STOPPED:
|
||||||
writePlaybackPreferencesNoMediaPlaying();
|
writePlaybackPreferencesNoMediaPlaying();
|
||||||
|
stopSelf();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue