diff options
author | egsavage <egs@egsavage.com> | 2018-10-07 19:23:34 -0400 |
---|---|---|
committer | egsavage <egs@egsavage.com> | 2018-10-07 19:48:31 -0400 |
commit | 98a19f0235f40377be7d402330e8f45269e112da (patch) | |
tree | 20ec91ddb7dbe309ac74b835adb741a88f885824 | |
parent | a59e5223afdbd4b69f2b3c99fb0994b01b82651c (diff) | |
download | AntennaPod-98a19f0235f40377be7d402330e8f45269e112da.zip |
Resolves #2829 - Make queue remaining time sensitive to playback speed
-rw-r--r-- | app/src/main/java/de/danoeh/antennapod/fragment/QueueFragment.java | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/QueueFragment.java b/app/src/main/java/de/danoeh/antennapod/fragment/QueueFragment.java index bae77d58b..f5fdd4f9c 100644 --- a/app/src/main/java/de/danoeh/antennapod/fragment/QueueFragment.java +++ b/app/src/main/java/de/danoeh/antennapod/fragment/QueueFragment.java @@ -21,7 +21,6 @@ import android.view.View; import android.view.ViewGroup; import android.widget.ProgressBar; import android.widget.TextView; -import android.widget.Toast; import com.yqritc.recyclerviewflexibledivider.HorizontalDividerItemDecoration; @@ -46,7 +45,6 @@ import de.danoeh.antennapod.core.service.download.Downloader; import de.danoeh.antennapod.core.storage.DBReader; import de.danoeh.antennapod.core.storage.DBTasks; import de.danoeh.antennapod.core.storage.DBWriter; -import de.danoeh.antennapod.core.storage.DownloadRequestException; import de.danoeh.antennapod.core.storage.DownloadRequester; import de.danoeh.antennapod.core.util.Converter; import de.danoeh.antennapod.core.util.FeedItemUtil; @@ -535,9 +533,12 @@ public class QueueFragment extends Fragment { String info = queue.size() + getString(R.string.episodes_suffix); if(queue.size() > 0) { long timeLeft = 0; + float playbackSpeed = Float.valueOf(UserPreferences.getPlaybackSpeed()); for(FeedItem item : queue) { if(item.getMedia() != null) { - timeLeft += item.getMedia().getDuration() - item.getMedia().getPosition(); + timeLeft += + (item.getMedia().getDuration() - item.getMedia().getPosition()) + / playbackSpeed; } } info += " \u2022 "; |