diff options
author | Klaus Schmidinger <vdr@tvdr.de> | 2012-12-04 10:09:08 +0100 |
---|---|---|
committer | Klaus Schmidinger <vdr@tvdr.de> | 2012-12-04 10:09:08 +0100 |
commit | 45a29931cbdce698c2fc03445dfd3cd74ea6600e (patch) | |
tree | 7d9321f1df222619c0ac03971f09554148527971 /menu.c | |
parent | f61645b4d2a73101c2a30c5b8b943bf96bc5da0d (diff) | |
download | vdr-45a29931cbdce698c2fc03445dfd3cd74ea6600e.tar.gz vdr-45a29931cbdce698c2fc03445dfd3cd74ea6600e.tar.bz2 |
The '7' and '9' keys now jump to the very beginning or end, respectively, of the recording, even if there is no mark set at that point
Diffstat (limited to 'menu.c')
-rw-r--r-- | menu.c | 12 |
1 files changed, 8 insertions, 4 deletions
@@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: menu.c 2.65 2012/11/18 13:07:53 kls Exp $ + * $Id: menu.c 2.66 2012/12/04 09:50:39 kls Exp $ */ #include "menu.h" @@ -4749,15 +4749,19 @@ void cReplayControl::MarkToggle(void) void cReplayControl::MarkJump(bool Forward) { - if (marks.Count()) { - int Current, Total; - if (GetIndex(Current, Total)) { + int Current, Total; + if (GetIndex(Current, Total)) { + if (marks.Count()) { cMark *m = Forward ? marks.GetNext(Current) : marks.GetPrev(Current); if (m) { Goto(m->Position(), true); displayFrames = true; + return; } } + // There are either no marks at all, or we already were at the first or last one, + // so jump to the very beginning or end: + Goto(Forward ? Total : 0, true); } } |