diff options
-rw-r--r-- | src/custommainmenuitem.cpp | 2 | ||||
-rw-r--r-- | src/custommainmenuitem.h | 5 | ||||
-rw-r--r-- | src/i18n.h | 6 | ||||
-rw-r--r-- | src/pluginmainmenuitem.cpp | 2 | ||||
-rw-r--r-- | src/pluginmainmenuitem.h | 5 | ||||
-rw-r--r-- | src/xmlmenu.cpp | 27 | ||||
-rw-r--r-- | src/xmlmenu.h | 2 | ||||
-rwxr-xr-x | submenu2menuorg (renamed from convert-submenu2menuorg.sh) | 4 |
8 files changed, 24 insertions, 29 deletions
diff --git a/src/custommainmenuitem.cpp b/src/custommainmenuitem.cpp index 2afded8..f2004ce 100644 --- a/src/custommainmenuitem.cpp +++ b/src/custommainmenuitem.cpp @@ -16,7 +16,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id$ + * $Id:$ * */ diff --git a/src/custommainmenuitem.h b/src/custommainmenuitem.h index 11316dd..1d18c1e 100644 --- a/src/custommainmenuitem.h +++ b/src/custommainmenuitem.h @@ -20,6 +20,9 @@ * */ +#ifndef ___CUSTOMMAINMENUITEM_H +#define ___CUSTOMMAINMENUITEM_H + #include <vdr/menuorgpatch.h> class CustomMainMenuItem: public MenuOrgPatch::IMainMenuItem @@ -35,3 +38,5 @@ class CustomMainMenuItem: public MenuOrgPatch::IMainMenuItem virtual const char* PluginMenuEntry(); virtual int PluginIndex(); }; + +#endif @@ -16,12 +16,12 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id:$ + * $Id$ * */ -#ifndef _I18N__H -#define _I18N__H +#ifndef ___I18N__H +#define ___I18N__H #include <vdr/i18n.h> diff --git a/src/pluginmainmenuitem.cpp b/src/pluginmainmenuitem.cpp index 6a47418..d617ee9 100644 --- a/src/pluginmainmenuitem.cpp +++ b/src/pluginmainmenuitem.cpp @@ -16,7 +16,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id$ + * $Id:$ * */ diff --git a/src/pluginmainmenuitem.h b/src/pluginmainmenuitem.h index ce54e3b..287ba0c 100644 --- a/src/pluginmainmenuitem.h +++ b/src/pluginmainmenuitem.h @@ -20,6 +20,9 @@ * */ +#ifndef ___PLUGINMAINMENUITEM_H +#define ___PLUGINMAINMENUITEM_H + #include <vdr/menuorgpatch.h> class PluginMainMenuItem: public MenuOrgPatch::IMainMenuItem @@ -36,3 +39,5 @@ class PluginMainMenuItem: public MenuOrgPatch::IMainMenuItem virtual const char* PluginMenuEntry(); virtual int PluginIndex(); }; + +#endif diff --git a/src/xmlmenu.cpp b/src/xmlmenu.cpp index f4e36c4..4b09772 100644 --- a/src/xmlmenu.cpp +++ b/src/xmlmenu.cpp @@ -16,12 +16,11 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id$ + * $Id:$ * */ #include "xmlmenu.h" -#include <iostream> #include <libxml++/libxml++.h> #include <exception> #include <vdr/plugin.h> @@ -38,10 +37,10 @@ MenuNode* XmlMenu::LoadXmlMenu(string menuFileName, string schemaFileName) try { - dsyslog("loading menuorg config file from %s and schema from %s",menuFileName.data(), schemaFileName.data()); + dsyslog("loading menuorg config file from %s and schema from %s", menuFileName.c_str(), schemaFileName.c_str()); DomParser parser; - parser.set_substitute_entities(); //We just want the text to be resolved/unescaped automatically. + parser.set_substitute_entities(); parser.parse_file(menuFileName); DtdValidator validator(schemaFileName); @@ -56,24 +55,9 @@ MenuNode* XmlMenu::LoadXmlMenu(string menuFileName, string schemaFileName) delete menuRoot; menuRoot = NULL; - //TODO: print output to syslog (isyslog or dsyslog?) - cout << "Exception caught: " << ex.what() << endl; - isyslog("Exception caught: %s", ex.what()); - //TODO: display message on osd + esyslog("Exception caught when parsing xml configuration: %s", ex.what()); } -/* - catch(const xmlpp::parse_error& ex) - { - // DTD or document is not well-formed - delete menuRoot; - menuRoot = NULL; - } - catch (const xmlpp::validation_error& ex) - { - // document is not valid - delete menuRoot; - menuRoot = NULL; - }*/ + return menuRoot; } @@ -179,5 +163,6 @@ bool XmlMenu::FindPluginByName(string name, const char** mainMenuEntry, int& plu } i++; } + return false; } diff --git a/src/xmlmenu.h b/src/xmlmenu.h index f8da182..55a595f 100644 --- a/src/xmlmenu.h +++ b/src/xmlmenu.h @@ -16,7 +16,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - * $Id$ + * $Id:$ * */ diff --git a/convert-submenu2menuorg.sh b/submenu2menuorg index 928ceab..0a2888e 100755 --- a/convert-submenu2menuorg.sh +++ b/submenu2menuorg @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash # # vdr-menuorg - A plugin for the Linux Video Disk Recorder # Copyright (C) 2007 Thomas Creutz, Tobias Grimm @@ -20,7 +20,7 @@ # $Id$ # -usage="convert-submenu2menuorg.sh submenu-file menuorg-file" +usage="$0 submenu-file menuorg-file" if [ a"$1" == a"" ] || ! [ -f $1 ]; then echo $usage && exit 1; fi if [ a"$2" == a"" ]; then echo $usage && exit 1; fi |