From 9ceabe93656984d2a6bb63bcd7e80379f2623ff6 Mon Sep 17 00:00:00 2001 From: svntobi Date: Sun, 19 Aug 2007 14:29:48 +0000 Subject: renamed VdrMenuItem to SystemMenuItem git-svn-id: file:///home/tobias/sandbox/vdr/--/vdr-pkg/vdr-pkg/submenu/trunk@5824 cd0d6b48-d4f9-0310-940f-ab8c4eb44d3f --- src/mainmenuitemsprovider.cpp | 2 +- src/submenuitem.cpp | 4 ++-- src/submenuitem.h | 6 +++--- src/systemmenuitem.cpp | 39 +++++++++++++++++++++++++++++++++++++++ src/systemmenuitem.h | 42 ++++++++++++++++++++++++++++++++++++++++++ src/vdrmenuitem.cpp | 39 --------------------------------------- src/vdrmenuitem.h | 42 ------------------------------------------ src/xmlmenu.cpp | 4 ++-- 8 files changed, 89 insertions(+), 89 deletions(-) create mode 100644 src/systemmenuitem.cpp create mode 100644 src/systemmenuitem.h delete mode 100644 src/vdrmenuitem.cpp delete mode 100644 src/vdrmenuitem.h (limited to 'src') diff --git a/src/mainmenuitemsprovider.cpp b/src/mainmenuitemsprovider.cpp index e408712..5895dd0 100644 --- a/src/mainmenuitemsprovider.cpp +++ b/src/mainmenuitemsprovider.cpp @@ -22,7 +22,7 @@ #include "mainmenuitemsprovider.h" #include "submenuitem.h" -#include "vdrmenuitem.h" +#include "systemmenuitem.h" #include "pluginmenuitem.h" #include diff --git a/src/submenuitem.cpp b/src/submenuitem.cpp index cd01591..0785018 100644 --- a/src/submenuitem.cpp +++ b/src/submenuitem.cpp @@ -16,13 +16,13 @@ * 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 "submenuitem.h" SubMenuItem::SubMenuItem(std::string itemText) - :VdrMenuItem(itemText, osUser1) + :SystemMenuItem(itemText, osUser1) { } diff --git a/src/submenuitem.h b/src/submenuitem.h index e380c74..2101dc6 100644 --- a/src/submenuitem.h +++ b/src/submenuitem.h @@ -16,17 +16,17 @@ * 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 ___SUBMENUITEM_H #define ___SUBMENUITEM_H -#include "vdrmenuitem.h" +#include "systemmenuitem.h" #include -class SubMenuItem: public VdrMenuItem +class SubMenuItem: public SystemMenuItem { public: SubMenuItem(std::string itemText); diff --git a/src/systemmenuitem.cpp b/src/systemmenuitem.cpp new file mode 100644 index 0000000..b62beef --- /dev/null +++ b/src/systemmenuitem.cpp @@ -0,0 +1,39 @@ +/* + * vdr-menuorg - A plugin for the Linux Video Disk Recorder + * Copyright (C) 2007 Thomas Creutz, Tobias Grimm + * + * 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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * $Id$ + * + */ + +#include "systemmenuitem.h" +#include +#include "custommainmenuitem.h" + +SystemMenuItem::SystemMenuItem(std::string itemText, eOSState itemState) +{ + _itemText = itemText; + _itemState = itemState; +} + +MenuOrgPatch::IMainMenuItem* SystemMenuItem::CreateMainMenuItem() +{ + if(_itemState != osUser1) + return new CustomMainMenuItem(new cOsdItem(tr(_itemText.c_str()), _itemState)); + else + return new CustomMainMenuItem(new cOsdItem(_itemText.c_str(), _itemState)); +} diff --git a/src/systemmenuitem.h b/src/systemmenuitem.h new file mode 100644 index 0000000..d7970c6 --- /dev/null +++ b/src/systemmenuitem.h @@ -0,0 +1,42 @@ +/* + * vdr-menuorg - A plugin for the Linux Video Disk Recorder + * Copyright (C) 2007 Thomas Creutz, Tobias Grimm + * + * 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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * $Id$ + * + */ + +#ifndef ___SYSTEMMENUITEM_H +#define ___SYSTEMMENUITEM_H + +#include "menunode.h" +#include +#include +#include + +class SystemMenuItem: public MenuNode +{ + private: + std::string _itemText; + eOSState _itemState; + + public: + SystemMenuItem(std::string itemText, eOSState itemState); + MenuOrgPatch::IMainMenuItem* CreateMainMenuItem(); +}; + +#endif diff --git a/src/vdrmenuitem.cpp b/src/vdrmenuitem.cpp deleted file mode 100644 index 758b73f..0000000 --- a/src/vdrmenuitem.cpp +++ /dev/null @@ -1,39 +0,0 @@ -/* - * vdr-menuorg - A plugin for the Linux Video Disk Recorder - * Copyright (C) 2007 Thomas Creutz, Tobias Grimm - * - * 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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id$ - * - */ - -#include "vdrmenuitem.h" -#include -#include "custommainmenuitem.h" - -VdrMenuItem::VdrMenuItem(std::string itemText, eOSState itemState) -{ - _itemText = itemText; - _itemState = itemState; -} - -MenuOrgPatch::IMainMenuItem* VdrMenuItem::CreateMainMenuItem() -{ - if(_itemState != osUser1) - return new CustomMainMenuItem(new cOsdItem(tr(_itemText.c_str()), _itemState)); - else - return new CustomMainMenuItem(new cOsdItem(_itemText.c_str(), _itemState)); -} diff --git a/src/vdrmenuitem.h b/src/vdrmenuitem.h deleted file mode 100644 index 8582e7c..0000000 --- a/src/vdrmenuitem.h +++ /dev/null @@ -1,42 +0,0 @@ -/* - * vdr-menuorg - A plugin for the Linux Video Disk Recorder - * Copyright (C) 2007 Thomas Creutz, Tobias Grimm - * - * 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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * $Id$ - * - */ - -#ifndef ___VDRMENUITEM_H -#define ___VDRMENUITEM_H - -#include "menunode.h" -#include -#include -#include - -class VdrMenuItem: public MenuNode -{ - private: - std::string _itemText; - eOSState _itemState; - - public: - VdrMenuItem(std::string itemText, eOSState itemState); - MenuOrgPatch::IMainMenuItem* CreateMainMenuItem(); -}; - -#endif diff --git a/src/xmlmenu.cpp b/src/xmlmenu.cpp index 04a8f8f..b050dbd 100644 --- a/src/xmlmenu.cpp +++ b/src/xmlmenu.cpp @@ -24,7 +24,7 @@ #include #include #include -#include "vdrmenuitem.h" +#include "systemmenuitem.h" #include "submenuitem.h" #include "pluginmenuitem.h" @@ -113,7 +113,7 @@ MenuNode* XmlMenu::AddSubMenuItem(string name, MenuNode* menu) void XmlMenu::AddSystemMenuItem(string name, MenuNode* menu) { - menu->AddChild(new VdrMenuItem(name, MenuTextToVdrState(name))); + menu->AddChild(new SystemMenuItem(name, MenuTextToVdrState(name))); } void XmlMenu::AddPluginMenuItem(string pluginName, MenuNode* menu) -- cgit v1.2.3