From 3fc29659759abb10154b78f9e3568407e523e1fc Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Sun, 8 Feb 2004 18:00:00 +0100 Subject: Version 1.3.4 - Fixed handling language codes in case there is no audio or Dolby PID. - Fixed handling CA ids (was broken in 1.3.3). - Fixed the SVDRP command 'STAT DISK' to avoid a 'division by 0' in case the disk is full (thanks to Jens Rosenboom). - Fixed handling bitmap indexes for 256 color mode (thanks to Andreas Regel). - Now handling "linked services" (based on the 'autopid' patch from Andreas Schultz). Linked channels are detected and added to 'channels.conf', but currently they are not yet presented to the user other than being in the normal channel list (this will come later). - Preliminary fix for the "Unknown picture type error" (thanks to Sascha Volkenandt for his support in debugging this one). This may slow down switching between channels on different transponders for now, but a better solution will come later. - Fixed the validity check for channel IDs, because some providers use TIDs with value 0 (thanks to Thomas Bergwinkl). - Enabled switching to a channel even if it has no Vpid or Apid set, because these might be automatically set when tuned to that transponder. - No longer closing the Channels menu after trying to switch to a channel that is currently not available. - Removed the now obsolete CaCaps stuff. The Setup/CICAM menu now displays the actual CAM type as reported by the CAM. The 'ca.conf' file has been stripped down to the values 0..4. --- channels.h | 24 +++++++++++++++++++++--- 1 file changed, 21 insertions(+), 3 deletions(-) (limited to 'channels.h') diff --git a/channels.h b/channels.h index 532a112..6d6dd3a 100644 --- a/channels.h +++ b/channels.h @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: channels.h 1.13 2004/01/25 15:31:16 kls Exp $ + * $Id: channels.h 1.15 2004/02/08 12:20:22 kls Exp $ */ #ifndef __CHANNELS_H @@ -59,13 +59,26 @@ public: tChannelID(void) { source = nid = tid = sid = rid = 0; } tChannelID(int Source, int Nid, int Tid, int Sid, int Rid = 0) { source = Source; nid = Nid; tid = Tid; sid = Sid; rid = Rid; } bool operator== (const tChannelID &arg) const; - bool Valid(void) { return tid && sid; } // nid and rid are optional and source may be 0//XXX source may not be 0??? + bool Valid(void) { return (nid || tid) && sid; } // rid is optional and source may be 0//XXX source may not be 0??? tChannelID &ClrRid(void) { rid = 0; return *this; } static tChannelID FromString(const char *s); const char *ToString(void); static const tChannelID InvalidID; }; +class cChannel; + +class cLinkChannel : public cListObject { +private: + cChannel *channel; +public: + cLinkChannel(cChannel *Channel) { channel = Channel; } + cChannel *Channel(void) { return channel; } + }; + +class cLinkChannels : public cList { + }; + class cChannel : public cListObject { friend class cMenuEditChannel; private: @@ -102,11 +115,14 @@ private: int hierarchy; int __EndData__; int modification; + cLinkChannels *linkChannels; + cChannel *refChannel; const char *ParametersToString(void); bool StringToParameters(const char *s); public: cChannel(void); - cChannel(const cChannel *Channel); + cChannel(const cChannel &Channel); + ~cChannel(); cChannel& operator= (const cChannel &Channel); const char *ToText(void); bool Parse(const char *s, bool AllowNonUniqueID = false); @@ -153,6 +169,8 @@ public: void SetPids(int Vpid, int Ppid, int *Apids, char ALangs[][4], int *Dpids, char DLangs[][4], int Tpid); void SetCaIds(const int *CaIds); // list must be zero-terminated void SetCaDescriptors(int Level); + void SetLinkChannels(cLinkChannels *LinkChannels); + void SetRefChannel(cChannel *RefChannel); }; class cChannels : public cRwLock, public cConfig { -- cgit v1.2.3