summaryrefslogtreecommitdiff
path: root/dvbplayer.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2006-04-09 13:57:39 +0200
committerKlaus Schmidinger <vdr@tvdr.de>2006-04-09 13:57:39 +0200
commita4520107608cdd4abf38153fd169a78408b18ca0 (patch)
tree60aed7511e4e20e4696fa3606cca4615aa40fe81 /dvbplayer.c
parent765f8267a5542af43b405cdb8440c5534a3a2a65 (diff)
downloadvdr-a4520107608cdd4abf38153fd169a78408b18ca0.tar.gz
vdr-a4520107608cdd4abf38153fd169a78408b18ca0.tar.bz2
Changed the behaviour when hitting the end of a recording in fast forward mode
Diffstat (limited to 'dvbplayer.c')
-rw-r--r--dvbplayer.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/dvbplayer.c b/dvbplayer.c
index f61e0c91..2f23e310 100644
--- a/dvbplayer.c
+++ b/dvbplayer.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: dvbplayer.c 1.43 2006/02/19 14:20:15 kls Exp $
+ * $Id: dvbplayer.c 1.44 2006/04/09 13:47:11 kls Exp $
*/
#include "dvbplayer.h"
@@ -399,12 +399,19 @@ void cDvbPlayer::Action(void)
if (playMode == pmFast || (playMode == pmSlow && playDir == pdBackward)) {
uchar FileNumber;
int FileOffset;
- int Index = index->GetNextIFrame(readIndex, playDir == pdForward, &FileNumber, &FileOffset, &Length, true);
+ bool TimeShiftMode = index->IsStillRecording();
+ int Index = index->GetNextIFrame(readIndex, playDir == pdForward, &FileNumber, &FileOffset, &Length, TimeShiftMode);
if (Index >= 0) {
if (!NextFile(FileNumber, FileOffset))
continue;
}
else {
+ if (!TimeShiftMode && playDir == pdForward) {
+ // hit end of recording: signal end of file but don't change playMode
+ readIndex = -1;
+ eof = true;
+ continue;
+ }
// hit begin of recording: wait for device buffers to drain
// before changing play mode:
if (!DeviceFlush(100))