From 4611af4339ec571573b57a566985514bb2c2f381 Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Sat, 15 Apr 2006 13:46:55 +0200 Subject: Implemented kNext and kPrev keys --- CONTRIBUTORS | 3 +++ HISTORY | 3 ++- MANUAL | 3 +++ i18n.c | 46 +++++++++++++++++++++++++++++++++++++++++++++- keys.c | 4 +++- keys.h | 4 +++- menu.c | 14 ++++++++++++-- vdr.c | 9 +++++++-- 8 files changed, 78 insertions(+), 8 deletions(-) diff --git a/CONTRIBUTORS b/CONTRIBUTORS index 912c3242..810670b9 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -1836,3 +1836,6 @@ Peter Dittmann Helge Lenz for reporting a bug in setting the 'Delta' parameter when calling the shutdown script with no active timer + +Peter Juszack + for a patch that was used as a base to implement kNext and kPrev diff --git a/HISTORY b/HISTORY index 1c8f1b9c..6802484e 100644 --- a/HISTORY +++ b/HISTORY @@ -4534,4 +4534,5 @@ Video Disk Recorder Revision History other than /usr/include/linux/dvb, you can define DVBDIR in the Make.config file (see also INSTALL). Any reference to DVBDIR should be removed from all plugins' Makefiles. Thanks to Marco Schlüßler for pointing out this problem. - +- Implemented kNext and kPrev keys (based on a patch from Peter Juszack). + See MANUAL for details. diff --git a/MANUAL b/MANUAL index c29d648e..f1fffbc8 100644 --- a/MANUAL +++ b/MANUAL @@ -45,6 +45,9 @@ Version 1.3 FastFwd fast forward FastRew fast rewind + Next Next/previous channel group (in live tv mode) + Prev or next/previous editing mark (in replay mode) + Channel+ channel up Channel- channel down diff --git a/i18n.c b/i18n.c index 70c37802..3d92a1a6 100644 --- a/i18n.c +++ b/i18n.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: i18n.c 1.258 2006/04/15 11:05:27 kls Exp $ + * $Id: i18n.c 1.259 2006/04/15 13:39:35 kls Exp $ * * Translations provided by: * @@ -5289,6 +5289,50 @@ const tI18nPhrase Phrases[] = { "Spol tilbage", "Dozadu", }, + { "Key$Next", + "Vorwärts", + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + }, + { "Key$Prev", + "Zurück", + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + }, { "Key$Power", "Ausschalten", "Izklop", diff --git a/keys.c b/keys.c index 9fd5552f..42967001 100644 --- a/keys.c +++ b/keys.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: keys.c 1.11 2006/01/16 17:01:25 kls Exp $ + * $Id: keys.c 1.12 2006/04/15 13:35:07 kls Exp $ */ #include "keys.h" @@ -39,6 +39,8 @@ static tKey keyTable[] = { // "Up" and "Down" must be the first two keys! { kRecord, "Record" }, { kFastFwd, "FastFwd" }, { kFastRew, "FastRew" }, + { kNext, "Next" }, + { kPrev, "Prev" }, { kPower, "Power" }, { kChanUp, "Channel+" }, { kChanDn, "Channel-" }, diff --git a/keys.h b/keys.h index 73e061e3..542b0f49 100644 --- a/keys.h +++ b/keys.h @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: keys.h 1.7 2006/01/05 15:39:06 kls Exp $ + * $Id: keys.h 1.8 2006/04/15 13:34:08 kls Exp $ */ #ifndef __KEYS_H @@ -33,6 +33,8 @@ enum eKeys { // "Up" and "Down" must be the first two keys! kRecord, kFastFwd, kFastRew, + kNext, + kPrev, kPower, kChanUp, kChanDn, diff --git a/menu.c b/menu.c index 56eb0685..5681c35d 100644 --- a/menu.c +++ b/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.430 2006/04/15 10:30:52 kls Exp $ + * $Id: menu.c 1.431 2006/04/15 13:37:09 kls Exp $ */ #include "menu.h" @@ -3158,6 +3158,10 @@ eOSState cDisplayChannel::ProcessKey(eKeys Key) case kLeft: case kRight|k_Repeat: case kRight: + case kNext|k_Repeat: + case kNext: + case kPrev|k_Repeat: + case kPrev: withInfo = false; number = 0; if (group < 0) { @@ -3167,7 +3171,7 @@ eOSState cDisplayChannel::ProcessKey(eKeys Key) } if (group >= 0) { int SaveGroup = group; - if (NORMALKEY(Key) == kRight) + if (NORMALKEY(Key) == kRight || NORMALKEY(Key) == kNext) group = Channels.GetNextGroup(group) ; else group = Channels.GetPrevGroup(group < 1 ? 1 : group); @@ -3201,6 +3205,8 @@ eOSState cDisplayChannel::ProcessKey(eKeys Key) case kDown|k_Release: case kChanUp|k_Release: case kChanDn|k_Release: + case kNext|k_Release: + case kPrev|k_Release: if (!(Key & k_Repeat) && channel && channel->Number() != cDevice::CurrentChannel()) NewChannel = channel; withInfo = true; @@ -4146,8 +4152,12 @@ eOSState cReplayControl::ProcessKey(eKeys Key) switch (Key) { // Editing: case kMarkToggle: MarkToggle(); break; + case kPrev|k_Repeat: + case kPrev: case kMarkJumpBack|k_Repeat: case kMarkJumpBack: MarkJump(false); break; + case kNext|k_Repeat: + case kNext: case kMarkJumpForward|k_Repeat: case kMarkJumpForward: MarkJump(true); break; case kMarkMoveBack|k_Repeat: diff --git a/vdr.c b/vdr.c index f11088fb..c3059d49 100644 --- a/vdr.c +++ b/vdr.c @@ -22,7 +22,7 @@ * * The project's page is at http://www.cadsoft.de/vdr * - * $Id: vdr.c 1.258 2006/04/15 11:29:13 kls Exp $ + * $Id: vdr.c 1.259 2006/04/15 13:35:40 kls Exp $ */ #include @@ -1061,11 +1061,16 @@ int main(int argc, char *argv[]) } // Direct Channel Select: case k1 ... k9: - // Left/Right rotates trough channel groups: + // Left/Right rotates through channel groups: case kLeft|k_Repeat: case kLeft: case kRight|k_Repeat: case kRight: + // Previous/Next rotates through channel groups: + case kPrev|k_Repeat: + case kPrev: + case kNext|k_Repeat: + case kNext: // Up/Down Channel Select: case kUp|k_Repeat: case kUp: -- cgit v1.2.3