mirror of
https://github.com/vdr-projects/vdr.git
synced 2025-03-01 10:50:46 +00:00
Implemented 'Rewind' in the 'Recordings' menu
This commit is contained in:
17
menu.c
17
menu.c
@@ -4,7 +4,7 @@
|
||||
* See the main source file 'vdr.c' for copyright information and
|
||||
* how to reach the author.
|
||||
*
|
||||
* $Id: menu.c 1.64 2001/02/10 15:34:35 kls Exp $
|
||||
* $Id: menu.c 1.65 2001/02/11 11:01:47 kls Exp $
|
||||
*/
|
||||
|
||||
#include "menu.h"
|
||||
@@ -1497,7 +1497,7 @@ cMenuRecordings::cMenuRecordings(void)
|
||||
recording = Recordings.Next(recording);
|
||||
}
|
||||
}
|
||||
SetHelp(tr("Play"), NULL, tr("Delete"), tr("Summary"));
|
||||
SetHelp(tr("Play"), tr("Rewind"), tr("Delete"), tr("Summary"));
|
||||
Display();
|
||||
}
|
||||
|
||||
@@ -1511,6 +1511,18 @@ eOSState cMenuRecordings::Play(void)
|
||||
return osContinue;
|
||||
}
|
||||
|
||||
eOSState cMenuRecordings::Rewind(void)
|
||||
{
|
||||
cMenuRecordingItem *ri = (cMenuRecordingItem *)Get(Current());
|
||||
if (ri) {
|
||||
cDvbApi::PrimaryDvbApi->StopReplay(); // must do this first to be able to rewind the currently replayed recording
|
||||
cResumeFile ResumeFile(ri->recording->FileName());
|
||||
ResumeFile.Delete();
|
||||
return Play();
|
||||
}
|
||||
return osContinue;
|
||||
}
|
||||
|
||||
eOSState cMenuRecordings::Del(void)
|
||||
{
|
||||
cMenuRecordingItem *ri = (cMenuRecordingItem *)Get(Current());
|
||||
@@ -1551,6 +1563,7 @@ eOSState cMenuRecordings::ProcessKey(eKeys Key)
|
||||
switch (Key) {
|
||||
case kOk:
|
||||
case kRed: return Play();
|
||||
case kGreen: return Rewind();
|
||||
case kYellow: return Del();
|
||||
case kBlue: return Summary();
|
||||
case kMenu: return osEnd;
|
||||
|
Reference in New Issue
Block a user