summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--COPYING18
-rw-r--r--Makefile3
-rw-r--r--README17
-rw-r--r--block.c14
-rw-r--r--config.c6
-rw-r--r--config.h2
-rw-r--r--control.c139
-rw-r--r--control.h22
-rw-r--r--event.c106
-rw-r--r--event.h18
-rw-r--r--i18n.c22
-rw-r--r--setup.c40
-rw-r--r--status.c7
13 files changed, 213 insertions, 201 deletions
diff --git a/COPYING b/COPYING
index 5b6e7c6..f90922e 100644
--- a/COPYING
+++ b/COPYING
@@ -2,7 +2,7 @@
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
- 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
@@ -15,7 +15,7 @@ software--to make sure the software is free for all its users. This
General Public License applies to most of the Free Software
Foundation's software and to any other program whose authors commit to
using it. (Some other Free Software Foundation software is covered by
-the GNU Library General Public License instead.) You can apply it to
+the GNU Lesser General Public License instead.) You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
@@ -55,7 +55,7 @@ patent must be licensed for everyone's free use or not licensed at all.
The precise terms and conditions for copying, distribution and
modification follow.
-
+
GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
@@ -110,7 +110,7 @@ above, provided that you also meet all of these conditions:
License. (Exception: if the Program itself is interactive but
does not normally print such an announcement, your work based on
the Program is not required to print an announcement.)
-
+
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
@@ -168,7 +168,7 @@ access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.
-
+
4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License. Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
@@ -225,7 +225,7 @@ impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
-
+
8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
@@ -278,7 +278,7 @@ PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
END OF TERMS AND CONDITIONS
-
+
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
@@ -305,7 +305,7 @@ the "copyright" line and a pointer to where the full notice is found.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Also add information on how to contact you by electronic and paper mail.
@@ -336,5 +336,5 @@ necessary. Here is a sample; alter the names:
This General Public License does not permit incorporating your program into
proprietary programs. If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
-library. If this is what you want to do, use the GNU Library General
+library. If this is what you want to do, use the GNU Lesser General
Public License instead of this License.
diff --git a/Makefile b/Makefile
index adc5a3f..d3db6ad 100644
--- a/Makefile
+++ b/Makefile
@@ -110,10 +110,11 @@ dist: clean
@-rm -rf $(TMPDIR)/$(ARCHIVE)
@mkdir $(TMPDIR)/$(ARCHIVE)
@cp -a * $(TMPDIR)/$(ARCHIVE)
- @tar czf $(PACKAGE).tgz -C $(TMPDIR) --exclude debian --exclude CVS --exclude .svn $(ARCHIVE)
+ @tar czf $(PACKAGE).tgz -C $(TMPDIR) --exclude debian --exclude .git $(ARCHIVE)
@-rm -rf $(TMPDIR)/$(ARCHIVE)
@echo Distribution package created as $(PACKAGE).tgz
clean:
@-rm -f $(PODIR)/*.mo $(PODIR)/*.pot
@-rm -f $(OBJS) $(DEPFILE) *.so *.tgz core* *~ $(PODIR)/*.mo $(PODIR)/*.pot
+
diff --git a/README b/README
index 05108b9..62a80d5 100644
--- a/README
+++ b/README
@@ -15,7 +15,21 @@ Contact information (taste plugin):
Written by: Sascha Volkenandt <sascha at akv-soft dot de>
Project homepage: http://www.magoa.net/linux/index.php?view=taste
-See the file COPYING for license information.
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License along
+with this program; if not, write to the Free Software Foundation, Inc.,
+51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+See the file COPYING for the full license information.
Description:
@@ -46,4 +60,3 @@ For VDR versions <= 1.3.16 you will have to apply the included patch to the
VDR source in order to have multiple channels being blocked in a row.
Otherwise the block plugin will only skip the first channel. The patch
originates from the taste plugin and was written by Sascha Volkenandt.
-
diff --git a/block.c b/block.c
index 6b21b8f..b838703 100644
--- a/block.c
+++ b/block.c
@@ -113,26 +113,26 @@ void cPluginBlock::MainThreadHook()
{
cSchedulesLock schedLock;
const cSchedules *scheds = cSchedules::Schedules(schedLock);
-
+
if (scheds == NULL)
{
return;
}
-
+
const cSchedule *sched = scheds->GetSchedule(channel->GetChannelID());
if (sched == NULL)
{
return;
}
-
+
const cEvent *present = sched->GetPresentEvent();
const cEvent *follow = sched->GetFollowingEvent();
-
+
if (present == NULL)
{
return;
}
-
+
//TODO: check if isrequested is still necessary
// if (!cControlBlock::IsRequested() && !EventsBlock.Acceptable(present->Title()))
const char* title=present->Title();
@@ -145,9 +145,9 @@ void cPluginBlock::MainThreadHook()
cControl::Launch(new cControlBlock(channel, present, follow));
}
}
-}
+}
+
-
VDRPLUGINCREATOR(cPluginBlock); // Don't touch this!
diff --git a/config.c b/config.c
index a31d27c..b311fd2 100644
--- a/config.c
+++ b/config.c
@@ -15,9 +15,9 @@ cSetupBlock SetupBlock;
int cSetupBlock::LastChannel=0;
cSetupBlock::cSetupBlock(void):
- HideMenuEntry(0),
- MessageTimeout(2),
- DetectionMethod(0)
+ HideMenuEntry(0),
+ MessageTimeout(2),
+ DetectionMethod(0)
{
}
diff --git a/config.h b/config.h
index 12a3d52..413d4a2 100644
--- a/config.h
+++ b/config.h
@@ -14,7 +14,7 @@ public:
int MessageTimeout;
int DetectionMethod;
static int LastChannel;
-
+
cSetupBlock(void);
bool Parse(const char *Name, const char *Value);
};
diff --git a/control.c b/control.c
index c1ad30a..24724a8 100644
--- a/control.c
+++ b/control.c
@@ -17,18 +17,18 @@ bool cControlBlock::mRequested = false;
cControlBlock::cControlBlock(const cChannel *Channel, const cEvent *Present, const cEvent *Following):
cControl(new cPlayer),
- mChannel(Channel),
- mPresent(Present),
- mFollowing(Following),
- mStart(0),
- mSwitch(true),
- mOsd(NULL),
- direction(0)
+ mChannel(Channel),
+ mPresent(Present),
+ mFollowing(Following),
+ mStart(0),
+ mSwitch(true),
+ mOsd(NULL),
+ direction(0)
{
#if APIVERSNUM >= 10500
- SetNeedsFastResponse(true);
+ SetNeedsFastResponse(true);
#else
- needsFastResponse = true;
+ needsFastResponse = true;
#endif
cRemote::Put(kBack,true); //Hide OSD new version
@@ -36,8 +36,8 @@ cControlBlock::cControlBlock(const cChannel *Channel, const cEvent *Present, con
cControlBlock::~cControlBlock()
{
- if (mOsd != NULL)
- delete mOsd;
+ if (mOsd != NULL)
+ delete mOsd;
if (mRequested)
{
#ifdef LOGGING
@@ -57,92 +57,92 @@ cControlBlock::~cControlBlock()
}
}
- if (mSwitch) {
- int lastchannel=cSetupBlock::LastChannel;
- // possibly first or last available channel, fall back to old channel
+ if (mSwitch) {
+ int lastchannel=cSetupBlock::LastChannel;
+ // possibly first or last available channel, fall back to old channel
- if (direction == 0)
- direction = 1;
- if (!cDevice::SwitchChannel(direction) && (lastchannel != 0))
- Channels.SwitchTo(lastchannel);
+ if (direction == 0)
+ direction = 1;
+ if (!cDevice::SwitchChannel(direction) && (lastchannel != 0))
+ Channels.SwitchTo(lastchannel);
- }
+ }
}
void cControlBlock::Show(void)
{
- if (mOsd == NULL)
- mOsd = Skins.Current()->DisplayChannel(true);
+ if (mOsd == NULL)
+ mOsd = Skins.Current()->DisplayChannel(true);
- mOsd->SetChannel(mChannel, 0);
- mOsd->SetEvents(mPresent, mFollowing);
- mOsd->SetMessage(mtError, tr("Channel not acceptable!"));
- mOsd->Flush();
+ mOsd->SetChannel(mChannel, 0);
+ mOsd->SetEvents(mPresent, mFollowing);
+ mOsd->SetMessage(mtError, tr("Channel not acceptable!"));
+ mOsd->Flush();
- mStart = time_ms();
+ mStart = time_ms();
}
eOSState cControlBlock::ProcessKey(eKeys Key)
{
#ifdef LOGGING
- dsyslog("plugin-block: userint cControlBlock::ProcessKey(%d) this = %p", Key, this);
+ dsyslog("plugin-block: userint cControlBlock::ProcessKey(%d) this = %p", Key, this);
#endif
switch (Key) {
- case kOk:
+ case kOk:
#ifdef LOGGING
- dsyslog("plugin-block: userint Processing 'Ok' event");
-#endif
- mRequested = true;
- mSwitch = false;
- return osEnd;
+ dsyslog("plugin-block: userint Processing 'Ok' event");
+#endif
+ mRequested = true;
+ mSwitch = false;
+ return osEnd;
- case kNone:
+ case kNone:
#ifdef LOGGING
dsyslog("plugin-block: userint Processing kNone (no user interaction)");
#endif
- if (mStart == 0)
- Show();
- else if (time_ms() - mStart > BlockTimeout()) {
- direction = mChannel->Number() - cSetupBlock::LastChannel;
- mSwitch = true;
- return osEnd;
- }
- return osContinue;
-
-
-
- case kUp:
- case kChanUp:
+ if (mStart == 0)
+ Show();
+ else if (time_ms() - mStart > BlockTimeout()) {
+ direction = mChannel->Number() - cSetupBlock::LastChannel;
+ mSwitch = true;
+ return osEnd;
+ }
+ return osContinue;
+
+
+
+ case kUp:
+ case kChanUp:
#ifdef LOGGING
dsyslog("plugin-block: userint Processing up event (userrequest)");
#endif
- if (mStart == 0)
- Show();
- else
- {
- mRequested=false;//TODO:necessary? as below
- direction = 1;
- mSwitch = true;
- return osEnd;
- }
- break;
- case kDown:
- case kChanDn:
+ if (mStart == 0)
+ Show();
+ else
+ {
+ mRequested=false;//TODO:necessary? as below
+ direction = 1;
+ mSwitch = true;
+ return osEnd;
+ }
+ break;
+ case kDown:
+ case kChanDn:
#ifdef LOGGING
dsyslog("plugin-block: userint Processing down event (userrequest)");
#endif
- if (mStart == 0)
- Show();
- else
- {
- mRequested=false;//TODO:necessary? as below
- direction = -1;
- mSwitch = true;
- return osEnd;
- }
- break;
+ if (mStart == 0)
+ Show();
+ else
+ {
+ mRequested=false;//TODO:necessary? as below
+ direction = -1;
+ mSwitch = true;
+ return osEnd;
+ }
+ break;
default:
@@ -150,4 +150,3 @@ dsyslog("plugin-block: userint Processing down event (userrequest)");
}
return osContinue;
}
-
diff --git a/control.h b/control.h
index 4bc24a3..78d1d8b 100644
--- a/control.h
+++ b/control.h
@@ -13,18 +13,18 @@
class cControlBlock : public cControl {
private:
- static bool mRequested;
-
- const cChannel *mChannel;
- const cEvent *mPresent;
- const cEvent *mFollowing;
- uint64_t mStart;
- bool mSwitch;
- cSkinDisplayChannel *mOsd;
- int direction;
+ static bool mRequested;
+
+ const cChannel *mChannel;
+ const cEvent *mPresent;
+ const cEvent *mFollowing;
+ uint64_t mStart;
+ bool mSwitch;
+ cSkinDisplayChannel *mOsd;
+ int direction;
protected:
- virtual void Show(void);
+ virtual void Show(void);
virtual void Hide(void) {}
public:
@@ -33,7 +33,7 @@ public:
virtual eOSState ProcessKey(eKeys Key);
- static bool IsRequested(void) { bool r = mRequested; mRequested = false; return r; }
+ static bool IsRequested(void) { bool r = mRequested; mRequested = false; return r; }
};
#endif // VDR_BLOCK_CONTROL_H
diff --git a/event.c b/event.c
index d06040a..82ede99 100644
--- a/event.c
+++ b/event.c
@@ -10,94 +10,94 @@
#include <ctype.h>
static char *duptolower(const char *s) {
- char *c = strdup(s);
- char *p = c;
- for (; *p; ++p)
- *p = tolower(*p);
- return c;
+ char *c = strdup(s);
+ char *p = c;
+ for (; *p; ++p)
+ *p = tolower(*p);
+ return c;
}
cEventsBlock EventsBlock;
cEventBlock::cEventBlock(void):
- mRegularExp(false),
- mIgnoreCase(false),
- mCompiled(false)
+ mRegularExp(false),
+ mIgnoreCase(false),
+ mCompiled(false)
{
strncpy(mPattern, tr("New Entry"), sizeof(mPattern));
}
cEventBlock::cEventBlock(const char *Pattern):
- mRegularExp(false),
- mIgnoreCase(false),
- mCompiled(false)
+ mRegularExp(false),
+ mIgnoreCase(false),
+ mCompiled(false)
{
strncpy(mPattern, Pattern, sizeof(mPattern));
}
cEventBlock::cEventBlock(const cEventBlock &Src)
{
- operator=(Src);
+ operator=(Src);
}
cEventBlock &cEventBlock::operator=(const cEventBlock &Src)
{
- printf("copy construct\n");
- strcpy(mPattern, Src.mPattern);
- mRegularExp = Src.mRegularExp;
- mIgnoreCase = Src.mIgnoreCase;
- mCompiled = false;
- Compile();
- return *this;
+ printf("copy construct\n");
+ strcpy(mPattern, Src.mPattern);
+ mRegularExp = Src.mRegularExp;
+ mIgnoreCase = Src.mIgnoreCase;
+ mCompiled = false;
+ Compile();
+ return *this;
}
cEventBlock::~cEventBlock()
{
- if (mRegularExp)
- regfree(&mExpression);
+ if (mRegularExp)
+ regfree(&mExpression);
}
bool cEventBlock::Acceptable(const char *Event) const
{
- if (mRegularExp)
- return regexec(&mExpression, Event, 0, NULL, 0) != 0;
- else if (mIgnoreCase) {
- char *ev = duptolower(Event);
- char *pa = duptolower(mPattern);
- printf("check for %s in %s\n", pa, ev);
- bool res = strstr(ev, pa) == NULL;
- free(ev); free(pa);
- return res;
- } else
- return strstr(Event, mPattern) == NULL;
+ if (mRegularExp)
+ return regexec(&mExpression, Event, 0, NULL, 0) != 0;
+ else if (mIgnoreCase) {
+ char *ev = duptolower(Event);
+ char *pa = duptolower(mPattern);
+ printf("check for %s in %s\n", pa, ev);
+ bool res = strstr(ev, pa) == NULL;
+ free(ev); free(pa);
+ return res;
+ } else
+ return strstr(Event, mPattern) == NULL;
}
bool cEventBlock::Parse(char *s) {
- char *patternbuf = NULL;
- int fields = sscanf(s, "%d:%d:%a[^\n]", &mRegularExp, &mIgnoreCase, &patternbuf);
-
- if (fields == 3) {
- strncpy(mPattern, skipspace(stripspace(patternbuf)), sizeof(mPattern));
- free(patternbuf);
- } else { // backward compatibility
- strncpy(mPattern, skipspace(stripspace(s)), sizeof(mPattern));
- mRegularExp = false;
- mIgnoreCase = false;
- }
+ char *patternbuf = NULL;
+ int fields = sscanf(s, "%d:%d:%a[^\n]", &mRegularExp, &mIgnoreCase, &patternbuf);
+
+ if (fields == 3) {
+ strncpy(mPattern, skipspace(stripspace(patternbuf)), sizeof(mPattern));
+ free(patternbuf);
+ } else { // backward compatibility
+ strncpy(mPattern, skipspace(stripspace(s)), sizeof(mPattern));
+ mRegularExp = false;
+ mIgnoreCase = false;
+ }
return Compile();
}
bool cEventBlock::Compile(void) {
- mCompiled = false;
- if (mRegularExp) {
- if (regcomp(&mExpression, mPattern, REG_EXTENDED | (mIgnoreCase ? REG_ICASE : 0)) != 0) {
- esyslog("ERROR: malformed regular expression: %s", mPattern);
- return false;
- } else
- mCompiled = true;
- }
- return true;
+ mCompiled = false;
+ if (mRegularExp) {
+ if (regcomp(&mExpression, mPattern, REG_EXTENDED | (mIgnoreCase ? REG_ICASE : 0)) != 0) {
+ esyslog("ERROR: malformed regular expression: %s", mPattern);
+ return false;
+ } else
+ mCompiled = true;
+ }
+ return true;
}
bool cEventBlock::Save(FILE *f) {
@@ -116,7 +116,7 @@ bool cEventsBlock::Acceptable(const char *Event) {
cEventsBlock &cEventsBlock::operator=(const cEventsBlock &Source) {
cList<cEventBlock>::Clear();
-
+
const cEventBlock *event = Source.First();
while (event != NULL) {
printf("transfering %p\n", event);
diff --git a/event.h b/event.h
index 3b8c34c..94c1d64 100644
--- a/event.h
+++ b/event.h
@@ -10,7 +10,7 @@
#include <sys/types.h>
#include <regex.h>
-
+
#include <vdr/tools.h>
#include <vdr/config.h>
@@ -21,24 +21,24 @@ class cEventBlock : public cListObject {
private:
char mPattern[EVLINELENGTH];
- int mRegularExp;
- int mIgnoreCase;
- bool mCompiled;
+ int mRegularExp;
+ int mIgnoreCase;
+ bool mCompiled;
- regex_t mExpression;
+ regex_t mExpression;
public:
cEventBlock(void);
cEventBlock(const char *Pattern);
- cEventBlock(const cEventBlock &Src);
- ~cEventBlock();
+ cEventBlock(const cEventBlock &Src);
+ ~cEventBlock();
- cEventBlock &operator=(const cEventBlock &Src);
+ cEventBlock &operator=(const cEventBlock &Src);
bool Acceptable(const char *Event) const ;
bool Parse(char *s);
- bool Compile(void);
+ bool Compile(void);
bool Save(FILE *f);
const char *Pattern(void) const { return mPattern; }
diff --git a/i18n.c b/i18n.c
index a2f4302..efc7cae 100644
--- a/i18n.c
+++ b/i18n.c
@@ -9,7 +9,7 @@
#if VDRVERSNUM < 10507
const tI18nPhrase Phrases[] = {
- /*
+ /*
{ "English",
"Deutsch",
"Slovenski",
@@ -31,7 +31,7 @@ const tI18nPhrase Phrases[] = {
"Eesti",
"Dansk",
},
- */
+ */
{ "Block broadcast",
"Sendung sperren",
"",
@@ -282,7 +282,7 @@ const tI18nPhrase Phrases[] = {
"",
#endif
},
- { "New",
+ { "New",
"Neu",
"",
"",
@@ -307,7 +307,7 @@ const tI18nPhrase Phrases[] = {
"",
#endif
},
- { "Delete keyword?",
+ { "Delete keyword?",
"Schlagwort löschen?",
"",
"",
@@ -332,7 +332,7 @@ const tI18nPhrase Phrases[] = {
"",
#endif
},
- { "Pattern",
+ { "Pattern",
"Suchmuster",
"",
"",
@@ -357,7 +357,7 @@ const tI18nPhrase Phrases[] = {
"",
#endif
},
- { "--- Keywords -------------------------------------------------------------------",
+ { "--- Keywords -------------------------------------------------------------------",
"--- Schlagworte ----------------------------------------------------------------",
"",
"",
@@ -382,7 +382,7 @@ const tI18nPhrase Phrases[] = {
"",
#endif
},
- { "Regular Expression",
+ { "Regular Expression",
"Regulärer Ausdruck",
"",
"",
@@ -407,7 +407,7 @@ const tI18nPhrase Phrases[] = {
"",
#endif
},
- { "Ignore Case",
+ { "Ignore Case",
"Groß/Kleinschreibung ignorieren",
"",
"",
@@ -432,7 +432,7 @@ const tI18nPhrase Phrases[] = {
"",
#endif
},
- { "Malformed regular expression!",
+ { "Malformed regular expression!",
"Ungültiger regulärer Ausdruck!",
"",
"",
@@ -457,7 +457,7 @@ const tI18nPhrase Phrases[] = {
"",
#endif
},
- { "Message Timeout [s]",
+ { "Message Timeout [s]",
"Wartezeit bis Umschalten [s]",
"",
"",
@@ -482,7 +482,7 @@ const tI18nPhrase Phrases[] = {
"",
#endif
},
- { NULL }
+ { NULL }
};
#endif
diff --git a/setup.c b/setup.c
index 42a4eb6..9a6c304 100644
--- a/setup.c
+++ b/setup.c
@@ -28,7 +28,7 @@ void cMenuSetupBlock::Set(void) {
DetectionMethods[0] = tr("On Switch");
DetectionMethods[1] = tr("Channel EPG");
-
+
Add(new cMenuEditStraItem(tr("Detection Method"), &mSetupData.DetectionMethod, 2, DetectionMethods));
item = new cOsdItem("");
@@ -62,8 +62,8 @@ void cMenuSetupBlock::SetHelpKeys(void)
printf("sethelpkeys, current = %d\n", Current());
if (Current() >= NONKEYWORDITEMS) {
- red = trVDR("Button$Edit");
- yellow = trVDR("Button$Delete");
+ red = trVDR("Button$Edit");
+ yellow = trVDR("Button$Delete");
}
SetHelp(red, trVDR("Button$New"), yellow, NULL);
}
@@ -104,11 +104,11 @@ eOSState cMenuSetupBlock::Delete(void)
{
if (HasSubMenu() || Current() < NONKEYWORDITEMS)
return osContinue;
-
+
cEventBlock *event = mEventsData.Get(Current() - NONKEYWORDITEMS);
if (event != NULL) {
- if (Interface->Confirm(tr("Delete keyword?")))
- mEventsData.Del(event);
+ if (Interface->Confirm(tr("Delete keyword?")))
+ mEventsData.Del(event);
}
Set();
return osContinue;
@@ -119,8 +119,8 @@ eOSState cMenuSetupBlock::ProcessKey(eKeys Key) {
eOSState state = cMenuSetupPage::ProcessKey(Key);
if (hadSubMenu && !HasSubMenu()) {
- Set();
- return state;
+ Set();
+ return state;
}
switch (state) {
@@ -138,9 +138,9 @@ eOSState cMenuSetupBlock::ProcessKey(eKeys Key) {
default:
break;
}
-
- if (!HasSubMenu())
- Set();
+
+ if (!HasSubMenu())
+ Set();
return state;
}
@@ -156,8 +156,8 @@ cMenuSetupEditBlock::cMenuSetupEditBlock(cEventBlock *Event):
snprintf(buf, sizeof(buf), "%s - %s '%s'", trVDR("Setup"), trVDR("Plugin"), "block");
SetTitle(buf);
Add(new cMenuEditStrItem(tr("Pattern"), mData.mPattern, sizeof(mData.mPattern), tr(ALLOWEDCHARS)));
- Add(new cMenuEditBoolItem(tr("Regular Expression"), &mData.mRegularExp));
- Add(new cMenuEditBoolItem(tr("Ignore Case"), &mData.mIgnoreCase));
+ Add(new cMenuEditBoolItem(tr("Regular Expression"), &mData.mRegularExp));
+ Add(new cMenuEditBoolItem(tr("Ignore Case"), &mData.mIgnoreCase));
}
eOSState cMenuSetupEditBlock::ProcessKey(eKeys Key)
@@ -167,13 +167,13 @@ eOSState cMenuSetupEditBlock::ProcessKey(eKeys Key)
if (state == osUnknown) {
switch (Key) {
case kOk:
- if (!mData.Compile()) {
- Skins.Message(mtError, tr("Malformed regular expression!"));
- state = osContinue;
- } else {
- *mEvent = mData;
- state = osBack;
- }
+ if (!mData.Compile()) {
+ Skins.Message(mtError, tr("Malformed regular expression!"));
+ state = osContinue;
+ } else {
+ *mEvent = mData;
+ state = osBack;
+ }
break;
default:
diff --git a/status.c b/status.c
index 70258cc..043077f 100644
--- a/status.c
+++ b/status.c
@@ -29,7 +29,7 @@ void cStatusBlock::ChannelSwitch(const cDevice *Device, int ChannelNumber)
cSetupBlock::LastChannel=cDevice::CurrentChannel();
return; //Switch in progress;
}
-
+
if (SetupBlock.DetectionMethod!=0) return;
#ifdef LOGGING
@@ -59,7 +59,7 @@ void cStatusBlock::ChannelSwitch(const cDevice *Device, int ChannelNumber)
#endif
return;
}
-
+
if (Device->Replaying())
{
#ifdef LOGGING
@@ -81,7 +81,7 @@ void cStatusBlock::ChannelSwitch(const cDevice *Device, int ChannelNumber)
const cEvent *present = sched->GetPresentEvent();
const cEvent *follow = sched->GetFollowingEvent();
if (present == NULL) return;
-
+
if (!cControlBlock::IsRequested() && !EventsBlock.Acceptable(present->Title()))
{
isyslog("plugin-block: channel %d is not acceptable at present", ChannelNumber);
@@ -89,4 +89,3 @@ void cStatusBlock::ChannelSwitch(const cDevice *Device, int ChannelNumber)
}
}
}
-