diff options
author | schmirl <schmirl> | 2007-04-23 11:42:16 +0000 |
---|---|---|
committer | schmirl <schmirl> | 2007-04-23 11:42:16 +0000 |
commit | e55981c9e1bbe128b0c45bb9c345f703a4851bf2 (patch) | |
tree | 2cd41d40a68dcf6089077cc9141e88d2060f1158 | |
parent | 35bfac507b1483f3d53a5e4c9e8bd1c653e4d647 (diff) | |
download | vdr-plugin-streamdev-e55981c9e1bbe128b0c45bb9c345f703a4851bf2.tar.gz vdr-plugin-streamdev-e55981c9e1bbe128b0c45bb9c345f703a4851bf2.tar.bz2 |
client_device.patch by Petri Hintukainen
- Implement virtual IsTunedToTransponder()
- Return true from Provides... functions
Modified Files:
client/device.c client/device.h
-rw-r--r-- | client/device.c | 15 | ||||
-rw-r--r-- | client/device.h | 5 |
2 files changed, 15 insertions, 5 deletions
diff --git a/client/device.c b/client/device.c index a2e4580..e2d857d 100644 --- a/client/device.c +++ b/client/device.c @@ -1,5 +1,5 @@ /* - * $Id: device.c,v 1.8 2007/01/15 12:15:12 schmirl Exp $ + * $Id: device.c,v 1.9 2007/04/23 11:42:16 schmirl Exp $ */ #include "client/device.h" @@ -59,13 +59,22 @@ cStreamdevDevice::~cStreamdevDevice() { bool cStreamdevDevice::ProvidesSource(int Source) const { Dprintf("ProvidesSource, Source=%d\n", Source); - return false; + return true; } bool cStreamdevDevice::ProvidesTransponder(const cChannel *Channel) const { Dprintf("ProvidesTransponder\n"); - return false; + return true; +} + +bool cStreamdevDevice::IsTunedToTransponder(const cChannel *Channel) +{ + bool res = false; + if (ClientSocket.DataSocket(siLive) != NULL + && TRANSPONDER(Channel, m_Channel)) + res = true; + return res; } bool cStreamdevDevice::ProvidesChannel(const cChannel *Channel, int Priority, diff --git a/client/device.h b/client/device.h index bdfabb6..3ef146f 100644 --- a/client/device.h +++ b/client/device.h @@ -1,5 +1,5 @@ /* - * $Id: device.h,v 1.3 2005/02/08 15:21:19 lordjaxom Exp $ + * $Id: device.h,v 1.4 2007/04/23 11:42:16 schmirl Exp $ */ #ifndef VDR_STREAMDEV_DEVICE_H @@ -51,9 +51,10 @@ public: virtual ~cStreamdevDevice(); virtual bool ProvidesSource(int Source) const; - virtual bool ProvidesTransponder(const cChannel *Channel) const; + virtual bool ProvidesTransponder(const cChannel *Channel) const; virtual bool ProvidesChannel(const cChannel *Channel, int Priority = -1, bool *NeedsDetachReceivers = NULL) const; + virtual bool IsTunedToTransponder(const cChannel *Channel); static bool Init(void); static bool ReInit(void); |