From ffcb38b9f770dd214ed5e5b45f6f5825a55b906c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20Skytt=C3=A4?= Date: Sun, 11 Mar 2012 19:32:14 +0200 Subject: Adapt to VDR 1.7.26 API changes. --- ttxtsubs.c | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/ttxtsubs.c b/ttxtsubs.c index 9781a26..e03ad16 100644 --- a/ttxtsubs.c +++ b/ttxtsubs.c @@ -136,7 +136,11 @@ public: // -- cStatus protected: - virtual void ChannelSwitch(const cDevice *Device, int ChannelNumber); + virtual void ChannelSwitch(const cDevice *Device, int ChannelNumber +#if APIVERSNUM >= 10726 + , bool LiveView +#endif + ); virtual void Replaying(const cControl *Control, const char *Name, const char *FileName, bool On); // virtual void OsdClear(void) { ShowTtxt(); } // virtual void OsdTitle(const char *Title) { HideTtxt(); } @@ -328,10 +332,17 @@ bool cPluginTtxtsubs::SetupParse(const char *Name, const char *Value) return true; } -void cPluginTtxtsubs::ChannelSwitch(const cDevice *Device, int ChannelNumber) +void cPluginTtxtsubs::ChannelSwitch(const cDevice *Device, int ChannelNumber +#if APIVERSNUM >= 10726 + , bool LiveView +#endif + ) { +#if APIVERSNUM < 10726 + bool LiveView = Device->IsPrimaryDevice(); +#endif //dprint("cPluginTtxtsubs::ChannelSwitch(devicenr: %d, channelnr: %d) - mDispl: %x\n", Device->DeviceNumber(), ChannelNumber, mDispl); // XXX - if (Device->IsPrimaryDevice() && !Device->Replaying() && ChannelNumber) + if (LiveView && !Device->Replaying() && ChannelNumber) { StopTtxt(); DELETENULL(mLiveReceiver); -- cgit v1.2.3