summaryrefslogtreecommitdiff
path: root/channels.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2006-05-28 10:48:50 +0200
committerKlaus Schmidinger <vdr@tvdr.de>2006-05-28 10:48:50 +0200
commite892171736157127d1ca8fd6b5c6193eb5b55c53 (patch)
treef0896244778df5d2129753d88b1f497b8a4e8fcb /channels.c
parent39162a98f081d997ad34c1d8dfb48111176eac15 (diff)
downloadvdr-e892171736157127d1ca8fd6b5c6193eb5b55c53.tar.gz
vdr-e892171736157127d1ca8fd6b5c6193eb5b55c53.tar.bz2
Fixed deleting channels in case the current channel's number changes1.4.0-2
Diffstat (limited to 'channels.c')
-rw-r--r--channels.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/channels.c b/channels.c
index 343802ee..4f1d3951 100644
--- a/channels.c
+++ b/channels.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: channels.c 1.51 2006/04/17 12:18:57 kls Exp $
+ * $Id: channels.c 1.52 2006/05/28 10:14:18 kls Exp $
*/
#include "channels.h"
@@ -925,6 +925,17 @@ int cChannels::GetNextNormal(int Idx)
return channel ? Idx : -1;
}
+#if APIVERSNUM != 10400
+#warning ******* API version changed - activate new code
+int cChannels::GetPrevNormal(int Idx)
+{
+ cChannel *channel = Get(--Idx);
+ while (channel && channel->GroupSep())
+ channel = Get(--Idx);
+ return channel ? Idx : -1;
+}
+#endif
+
void cChannels::ReNumber( void )
{
channelsHashSid.Clear();