Merge pull request #3498 from ByteHamster/fix-mono-switch

Fixed downmixing if service is not bound
This commit is contained in:
H. Lehmann 2019-10-06 12:57:07 +02:00 committed by GitHub
commit f750e06a1b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 11 deletions

View File

@ -503,16 +503,6 @@ public class PlaybackController {
PlaybackServiceMediaPlayer.PSMPInfo info = playbackService.getPSMPInfo();
status = info.playerStatus;
media = info.playable;
/*
if (media == null) {
Log.w(TAG,
"PlaybackService has no media object. Trying to restore last played media.");
Intent serviceIntent = getPlayLastPlayedMediaIntent();
if (serviceIntent != null) {
ContextCompat.startForegroundService(activity, serviceIntent);
}
}
*/
onServiceQueried();
setupGUI();
@ -720,7 +710,8 @@ public class PlaybackController {
}
public boolean canDownmix() {
return playbackService != null && playbackService.canDownmix();
return (playbackService != null && playbackService.canDownmix())
|| UserPreferences.useSonic();
}
public void setDownmix(boolean enable) {