From 6392f7abd4c778e2058c7a37bea2c6cfdde26496 Mon Sep 17 00:00:00 2001 From: Martin Fietz Date: Sun, 24 Jan 2016 12:59:25 +0100 Subject: Eliminate confusion from UI elements that change playback speed --- .../danoeh/antennapod/core/util/playback/PlaybackController.java | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'core/src/main') diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/playback/PlaybackController.java b/core/src/main/java/de/danoeh/antennapod/core/util/playback/PlaybackController.java index 31cb25d40..27935978c 100644 --- a/core/src/main/java/de/danoeh/antennapod/core/util/playback/PlaybackController.java +++ b/core/src/main/java/de/danoeh/antennapod/core/util/playback/PlaybackController.java @@ -11,6 +11,7 @@ import android.content.SharedPreferences; import android.content.res.TypedArray; import android.media.MediaPlayer; import android.os.AsyncTask; +import android.os.Build; import android.os.IBinder; import android.preference.PreferenceManager; import android.support.annotation.NonNull; @@ -34,6 +35,7 @@ import de.danoeh.antennapod.core.feed.Chapter; import de.danoeh.antennapod.core.feed.FeedMedia; import de.danoeh.antennapod.core.feed.MediaType; import de.danoeh.antennapod.core.preferences.PlaybackPreferences; +import de.danoeh.antennapod.core.preferences.UserPreferences; import de.danoeh.antennapod.core.service.playback.PlaybackService; import de.danoeh.antennapod.core.service.playback.PlaybackServiceMediaPlayer; import de.danoeh.antennapod.core.service.playback.PlayerStatus; @@ -677,6 +679,11 @@ public abstract class PlaybackController { } public boolean canSetPlaybackSpeed() { + if (org.antennapod.audio.MediaPlayer.isPrestoLibraryInstalled(activity.getApplicationContext()) + || UserPreferences.useSonic() + || Build.VERSION.SDK_INT >= 23) { + return true; + } return playbackService != null && playbackService.canSetSpeed(); } -- cgit v1.2.3