diff options
author | Frank Schmirler <vdr@schmirler.de> | 2011-02-16 08:57:05 +0100 |
---|---|---|
committer | Frank Schmirler <vdr@schmirler.de> | 2011-02-16 08:57:05 +0100 |
commit | dc41eecffdbac79b1cfddadb335b7952caf8cecf (patch) | |
tree | f58cd97b26b4b8a01cf7567c2d55b9ec63a2f599 /client | |
parent | 30930d5c74587d04c5f2453676e943899a536601 (diff) | |
download | vdr-plugin-streamdev-dc41eecffdbac79b1cfddadb335b7952caf8cecf.tar.gz vdr-plugin-streamdev-dc41eecffdbac79b1cfddadb335b7952caf8cecf.tar.bz2 |
return value of streamdev-clients cDevice::NumProvidedSystems() now
configurable in plugin setup (fixes #552)
Diffstat (limited to 'client')
-rw-r--r-- | client/device.c | 5 | ||||
-rw-r--r-- | client/device.h | 2 | ||||
-rw-r--r-- | client/po/de_DE.po | 4 | ||||
-rw-r--r-- | client/setup.c | 10 | ||||
-rw-r--r-- | client/setup.h | 3 |
5 files changed, 22 insertions, 2 deletions
diff --git a/client/device.c b/client/device.c index fb80107..9e78f80 100644 --- a/client/device.c +++ b/client/device.c @@ -56,6 +56,11 @@ cStreamdevDevice::~cStreamdevDevice() { DELETENULL(m_TSBuffer); } +#if APIVERSNUM >= 10700 +int cStreamdevDevice::NumProvidedSystems(void) const +{ return StreamdevClientSetup.NumProvidedSystems; } +#endif + bool cStreamdevDevice::ProvidesSource(int Source) const { Dprintf("ProvidesSource, Source=%d\n", Source); return true; diff --git a/client/device.h b/client/device.h index b2eed70..5eb9e53 100644 --- a/client/device.h +++ b/client/device.h @@ -56,7 +56,7 @@ public: virtual bool ProvidesChannel(const cChannel *Channel, int Priority = -1, bool *NeedsDetachReceivers = NULL) const; #if APIVERSNUM >= 10700 - virtual int NumProvidedSystems(void) const { return 1; } + virtual int NumProvidedSystems(void) const; #endif virtual bool IsTunedToTransponder(const cChannel *Channel); diff --git a/client/po/de_DE.po b/client/po/de_DE.po index 1e481a2..d6db114 100644 --- a/client/po/de_DE.po +++ b/client/po/de_DE.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: streamdev 0.5.0\n" "Report-Msgid-Bugs-To: <http://www.vdr-developer.org/mantisbt/>\n" -"POT-Creation-Date: 2010-06-14 13:05+0200\n" +"POT-Creation-Date: 2011-02-16 08:49+0100\n" "PO-Revision-Date: 2008-03-30 02:11+0200\n" "Last-Translator: Frank Schmirler <vdrdev@schmirler.de>\n" "Language-Team: <vdr@linuxtv.org>\n" @@ -48,3 +48,5 @@ msgstr "Minimale Priorität" msgid "Maximum Priority" msgstr "Maximale Priorität" +msgid "Broadcast Systems / Cost" +msgstr "Empfangssysteme / Kosten" diff --git a/client/setup.c b/client/setup.c index dd337c8..907c294 100644 --- a/client/setup.c +++ b/client/setup.c @@ -16,6 +16,9 @@ cStreamdevClientSetup::cStreamdevClientSetup(void) { HideMenuEntry = false; MinPriority = -1; MaxPriority = MAXPRIORITY; +#if APIVERSNUM >= 10700 + NumProvidedSystems = 1; +#endif strcpy(RemoteIp, ""); } @@ -32,6 +35,7 @@ bool cStreamdevClientSetup::SetupParse(const char *Name, const char *Value) { else if (strcmp(Name, "HideMenuEntry") == 0) HideMenuEntry = atoi(Value); else if (strcmp(Name, "MinPriority") == 0) MinPriority = atoi(Value); else if (strcmp(Name, "MaxPriority") == 0) MaxPriority = atoi(Value); + else if (strcmp(Name, "NumProvidedSystems") == 0) NumProvidedSystems = atoi(Value); else return false; return true; } @@ -46,6 +50,11 @@ cStreamdevClientMenuSetupPage::cStreamdevClientMenuSetupPage(void) { Add(new cMenuEditBoolItem(tr("Filter Streaming"), &m_NewSetup.StreamFilters)); Add(new cMenuEditIntItem (tr("Minimum Priority"), &m_NewSetup.MinPriority, -1, MAXPRIORITY)); Add(new cMenuEditIntItem (tr("Maximum Priority"), &m_NewSetup.MaxPriority, -1, MAXPRIORITY)); +#if APIVERSNUM >= 10715 + Add(new cMenuEditIntItem (tr("Broadcast Systems / Cost"), &m_NewSetup.NumProvidedSystems, 1, 15)); +#elif APIVERSNUM >= 10700 + Add(new cMenuEditIntItem (tr("Broadcast Systems / Cost"), &m_NewSetup.NumProvidedSystems, 1, 4)); +#endif SetCurrent(Get(0)); } @@ -68,6 +77,7 @@ void cStreamdevClientMenuSetupPage::Store(void) { SetupStore("HideMenuEntry", m_NewSetup.HideMenuEntry); SetupStore("MinPriority", m_NewSetup.MinPriority); SetupStore("MaxPriority", m_NewSetup.MaxPriority); + SetupStore("NumProvidedSystems", m_NewSetup.NumProvidedSystems); StreamdevClientSetup = m_NewSetup; diff --git a/client/setup.h b/client/setup.h index 6049967..ba2b9d0 100644 --- a/client/setup.h +++ b/client/setup.h @@ -19,6 +19,9 @@ struct cStreamdevClientSetup { int HideMenuEntry; int MinPriority; int MaxPriority; +#if APIVERSNUM >= 10700 + int NumProvidedSystems; +#endif }; extern cStreamdevClientSetup StreamdevClientSetup; |