summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDimitar Petrovski <dimeptr@gmail.com>2012-05-24 10:49:55 +0200
committerDimitar Petrovski <dimeptr@gmail.com>2012-05-24 10:49:55 +0200
commit80c9c7fa84f17dbe2779c2a27dac82a001e33101 (patch)
tree6f3d49ea78d94d2d46589c2100de6686da69e227
parent7089617d8186143cfe946596dfafd650cb3028f9 (diff)
downloadvdr-plugin-eepg-80c9c7fa84f17dbe2779c2a27dac82a001e33101.tar.gz
vdr-plugin-eepg-80c9c7fa84f17dbe2779c2a27dac82a001e33101.tar.bz2
add namespace util
-rw-r--r--eepg.c1
-rw-r--r--equivhandler.c1
-rw-r--r--util.c7
-rw-r--r--util.h9
4 files changed, 14 insertions, 4 deletions
diff --git a/eepg.c b/eepg.c
index 337e93a..563c2f4 100644
--- a/eepg.c
+++ b/eepg.c
@@ -73,6 +73,7 @@ template <class T> T REALLOC(T Var, size_t Size)
}
using namespace std;
+using namespace util;
const char *optPats[] = {
"%s",
diff --git a/equivhandler.c b/equivhandler.c
index 3c99534..9b0e989 100644
--- a/equivhandler.c
+++ b/equivhandler.c
@@ -12,6 +12,7 @@
#include <string>
+using namespace util;
multimap<string, string> cEquivHandler::equiChanMap;
long cEquivHandler::equiChanFileTime = 0;
diff --git a/util.c b/util.c
index 68708d7..b60547d 100644
--- a/util.c
+++ b/util.c
@@ -4,8 +4,11 @@
* Created on: 23.5.2012
* Author: d.petrovski
*/
+#include "util.h"
+#include <vdr/channels.h>
-int NumberOfAvailableSources = 0;
+namespace util
+{
cChannel *GetChannelByID(tChannelID & channelID, bool searchOtherPos)
{
@@ -110,4 +113,4 @@ void CleanString (unsigned char *String)
// LogD (1, prep("Clean: %s"), String);
}
-
+}
diff --git a/util.h b/util.h
index a94390a..8c12184 100644
--- a/util.h
+++ b/util.h
@@ -7,9 +7,14 @@
#ifndef UTIL_H_
#define UTIL_H_
+#include <time.h>
+class cChannel;
+struct tChannelID;
+namespace util
+{
int AvailableSources[32];
-int NumberOfAvailableSources;
+int NumberOfAvailableSources = 0;
int Yesterday;
int YesterdayEpoch;
@@ -20,5 +25,5 @@ time_t LocalTime2UTC (time_t t);
time_t UTC2LocalTime (time_t t);
void GetLocalTimeOffset (void);
void CleanString (unsigned char *String);
-
+}
#endif /* UTIL_H_ */