From e869bd9dc3601837f88d5ef24193a2900a2560c6 Mon Sep 17 00:00:00 2001 From: Martin Fietz Date: Thu, 31 Mar 2016 10:39:36 +0200 Subject: [PATCH] Make played time more accurate --- .../java/de/danoeh/antennapod/core/storage/DBReader.java | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/core/src/main/java/de/danoeh/antennapod/core/storage/DBReader.java b/core/src/main/java/de/danoeh/antennapod/core/storage/DBReader.java index 94629ba9d..869ec5f9d 100644 --- a/core/src/main/java/de/danoeh/antennapod/core/storage/DBReader.java +++ b/core/src/main/java/de/danoeh/antennapod/core/storage/DBReader.java @@ -949,12 +949,8 @@ public final class DBReader { continue; } - if(item.isPlayed()) { - feedPlayedTime += media.getDuration() / 1000; - } else { - feedPlayedTime += media.getPosition() / 1000; - } - if(item.isPlayed() || media.getPosition() != 0) { + feedPlayedTime += media.getPlayedDuration() / 1000; + if(media.getPlayedDuration() > 0) { episodesStarted++; } feedTotalTime += media.getDuration() / 1000;