diff options
author | Ville Skyttä <ville.skytta@iki.fi> | 2011-09-14 21:06:47 +0300 |
---|---|---|
committer | Christian Wieninger <cwieninger@gmx.de> | 2011-09-19 19:03:26 +0200 |
commit | 6b1323b84fca1bb1a2220fb7176da28d31a90509 (patch) | |
tree | 97c10b1d32b46f5b3d708d0a261011c6cd6e40c1 /patches | |
parent | eba9d263b17cfbde428c974faee080e5b27a71b2 (diff) | |
download | vdr-plugin-epgsearch-6b1323b84fca1bb1a2220fb7176da28d31a90509.tar.gz vdr-plugin-epgsearch-6b1323b84fca1bb1a2220fb7176da28d31a90509.tar.bz2 |
Remove obsolete patches.
Diffstat (limited to 'patches')
-rw-r--r-- | patches/README.patches | 4 | ||||
-rw-r--r-- | patches/timercmd-0.1_1.3.23.diff | 178 | ||||
-rw-r--r-- | patches/timercmd-0.1_1.3.25.diff | 142 | ||||
-rw-r--r-- | patches/timercmd-0.1_1.5.12.diff | 170 | ||||
-rw-r--r-- | patches/vdr-1.5.11-progressbar-support-0.0.1.diff | 113 |
5 files changed, 2 insertions, 605 deletions
diff --git a/patches/README.patches b/patches/README.patches index 376907c..83973cd 100644 --- a/patches/README.patches +++ b/patches/README.patches @@ -9,7 +9,7 @@ Description of patches - timercmd-0.1_1.x.diff: this patch adds a timer commands menu to VDR's timer menu, that can be called with '0'. It can be used e.g. to search for repeats of a timer. -- vdr-1.5.11-progressbar-support-0.0.1.diff: +- vdr-1.5.17-progressbar-support-0.0.1.diff: this patch adds progressbar support to VDR's skins 'classic' and 'st:tng' - vdr.epgsearch-exttimeredit.diff: - this patch against VDR integrates epgsearch's timer edit menu to VDR's timer menu.
\ No newline at end of file + this patch against VDR integrates epgsearch's timer edit menu to VDR's timer menu. diff --git a/patches/timercmd-0.1_1.3.23.diff b/patches/timercmd-0.1_1.3.23.diff deleted file mode 100644 index e5d2f3f..0000000 --- a/patches/timercmd-0.1_1.3.23.diff +++ /dev/null @@ -1,178 +0,0 @@ -diff -Nru vdr-1.3.23-orig/config.c vdr-1.3.23-timercmd/config.c ---- vdr-1.3.23-orig/config.c 2005-02-20 13:52:59.000000000 +0100 -+++ vdr-1.3.23-timercmd/config.c 2005-03-29 20:08:21.000000000 +0200 -@@ -141,6 +141,7 @@ - - cCommands Commands; - cCommands RecordingCommands; -+cCommands TimerCommands; - - // -- cSVDRPhosts ------------------------------------------------------------ - -diff -Nru vdr-1.3.23-orig/config.h vdr-1.3.23-timercmd/config.h ---- vdr-1.3.23-orig/config.h 2005-03-05 16:44:35.000000000 +0100 -+++ vdr-1.3.23-timercmd/config.h 2005-03-29 20:08:46.000000000 +0200 -@@ -173,6 +173,7 @@ - - extern cCommands Commands; - extern cCommands RecordingCommands; -+extern cCommands TimerCommands; - extern cSVDRPhosts SVDRPhosts; - extern cCaDefinitions CaDefinitions; - -diff -Nru vdr-1.3.23-orig/i18n.c vdr-1.3.23-timercmd/i18n.c ---- vdr-1.3.23-orig/i18n.c 2005-03-12 11:43:16.000000000 +0100 -+++ vdr-1.3.23-timercmd/i18n.c 2005-04-14 19:20:22.000000000 +0200 -@@ -315,6 +315,27 @@ - "Salvestuse käsud", - "Optage kommandoer", - }, -+ { "Timer commands", -+ "Befehle für Timer", -+ "Ukazi za termine", -+ "Timer comandi", -+ "",// "Nederlands" -+ "",// "Português" -+ "Commandes de programmation", -+ "Timer kommandoer", -+ "Ajastinkomennot", -+ "",// "Polski" -+ "Comandos de programacion", -+ "",// "ÅëëçíéêÜ", // Greek -+ "Timer kommandon", -+ "Comenzi timer", -+ "",// "Magyar" -+ "Ordres de programació", -+ "",// "ÀãááÚØÙ", // Russian -+ "Naredbe za termine", -+ "",// "Eesti" -+ "",// "Dansk" -+ }, - { "Edit channel", - "Kanal editieren", - "Uredi kanal", -diff -Nru vdr-1.3.23-orig/menu.c vdr-1.3.23-timercmd/menu.c ---- vdr-1.3.23-orig/menu.c 2005-03-20 16:14:51.000000000 +0100 -+++ vdr-1.3.23-timercmd/menu.c 2005-04-28 14:28:33.000000000 +0200 -@@ -707,8 +707,20 @@ - return state; - } - --// --- cMenuTimerItem -------------------------------------------------------- -+// --- cMenuCommands --------------------------------------------------------- -+// declaration shifted so it can be used in cMenuTimers -+class cMenuCommands : public cOsdMenu { -+private: -+ cCommands *commands; -+ char *parameters; -+ eOSState Execute(void); -+public: -+ cMenuCommands(const char *Title, cCommands *Commands, const char *Parameters = NULL); -+ virtual ~cMenuCommands(); -+ virtual eOSState ProcessKey(eKeys Key); -+ }; - -+// --- cMenuTimerItem -------------------------------------------------------- - class cMenuTimerItem : public cOsdItem { - private: - cTimer *timer; -@@ -773,6 +785,7 @@ - virtual void Move(int From, int To); - eOSState Summary(void); - cTimer *CurrentTimer(void); -+ eOSState Commands(eKeys Key = kNone); - public: - cMenuTimers(void); - virtual ~cMenuTimers(); -@@ -876,6 +889,53 @@ - return Edit(); // convenience for people not using the Summary feature ;-) - } - -+#define CHECK_2PTR_NULL(x_,y_) ((x_)? ((y_)? y_:""):"") -+ -+eOSState cMenuTimers::Commands(eKeys Key) -+{ -+ if (HasSubMenu() || Count() == 0) -+ return osContinue; -+ cTimer *ti = CurrentTimer(); -+ if (ti) { -+ char *parameter = NULL; -+ const cEvent *pEvent = ti->Event(); -+ int iRecNumber=0; -+ -+ if(!pEvent) { -+ Timers.SetEvents(); -+ pEvent = ti->Event(); -+ } -+ if(pEvent) { -+// create a dummy recording to get the real filename -+ cRecording *rc_dummy = new cRecording(ti, pEvent->Title(), pEvent->ShortText(), ""); -+ Recordings.Load(); -+ cRecording *rc = Recordings.GetByName(rc_dummy->FileName()); -+ -+ delete rc_dummy; -+ if(rc) -+ iRecNumber=rc->Index() + 1; -+ } -+//Parameter format TimerNumber 'ChannelId' Start Stop 'Titel' 'Subtitel' 'file' RecNumer -+// 1 2 3 4 5 6 7 8 -+ asprintf(¶meter, "%d '%s' %d %d '%s' '%s' '%s' %d", ti->Index(), -+ *ti->Channel()->GetChannelID().ToString(), -+ (int)ti->StartTime(), -+ (int)ti->StopTime(), -+ CHECK_2PTR_NULL(pEvent, pEvent->Title()), -+ CHECK_2PTR_NULL(pEvent, pEvent->ShortText()), -+ ti->File(), -+ iRecNumber); -+ isyslog("timercmd: %s", parameter); -+ cMenuCommands *menu; -+ eOSState state = AddSubMenu(menu = new cMenuCommands(tr("Timer commands"), &TimerCommands, parameter)); -+ free(parameter); -+ if (Key != kNone) -+ state = menu->ProcessKey(Key); -+ return state; -+ } -+ return osContinue; -+} -+ - eOSState cMenuTimers::ProcessKey(eKeys Key) - { - int TimerNumber = HasSubMenu() ? Count() : -1; -@@ -892,6 +951,8 @@ - else - Mark(); - break; -+ case k1...k9: return Commands(Key); -+ case k0: return (TimerCommands.Count()? Commands():osContinue); - default: break; - } - } -@@ -1240,17 +1301,6 @@ - - // --- cMenuCommands --------------------------------------------------------- - --class cMenuCommands : public cOsdMenu { --private: -- cCommands *commands; -- char *parameters; -- eOSState Execute(void); --public: -- cMenuCommands(const char *Title, cCommands *Commands, const char *Parameters = NULL); -- virtual ~cMenuCommands(); -- virtual eOSState ProcessKey(eKeys Key); -- }; -- - cMenuCommands::cMenuCommands(const char *Title, cCommands *Commands, const char *Parameters) - :cOsdMenu(Title) - { -diff -Nru vdr-1.3.23-orig/vdr.c vdr-1.3.23-timercmd/vdr.c ---- vdr-1.3.23-orig/vdr.c 2005-03-20 11:58:59.000000000 +0100 -+++ vdr-1.3.23-timercmd/vdr.c 2005-03-29 20:05:57.000000000 +0200 -@@ -393,6 +393,7 @@ - Timers.Load(AddDirectory(ConfigDirectory, "timers.conf")) && - Commands.Load(AddDirectory(ConfigDirectory, "commands.conf"), true) && - RecordingCommands.Load(AddDirectory(ConfigDirectory, "reccmds.conf"), true) && -+ TimerCommands.Load(AddDirectory(ConfigDirectory, "timercmds.conf"), true) && - SVDRPhosts.Load(AddDirectory(ConfigDirectory, "svdrphosts.conf"), true) && - CaDefinitions.Load(AddDirectory(ConfigDirectory, "ca.conf"), true) && - Keys.Load(AddDirectory(ConfigDirectory, "remote.conf")) && diff --git a/patches/timercmd-0.1_1.3.25.diff b/patches/timercmd-0.1_1.3.25.diff deleted file mode 100644 index 331330b..0000000 --- a/patches/timercmd-0.1_1.3.25.diff +++ /dev/null @@ -1,142 +0,0 @@ -diff -ruN7p1 vdr-1.3.25-orig/config.c vdr-1.3.25/config.c ---- vdr-1.3.25-orig/config.c 2005-02-20 13:52:59.000000000 +0100 -+++ vdr-1.3.25/config.c 2005-05-31 00:07:56.000000000 +0200 -@@ -143,2 +143,3 @@ cCommands Commands; - cCommands RecordingCommands; -+cCommands TimerCommands; - -diff -ruN7p1 vdr-1.3.25-orig/config.h vdr-1.3.25/config.h ---- vdr-1.3.25-orig/config.h 2005-05-14 11:18:08.000000000 +0200 -+++ vdr-1.3.25/config.h 2005-05-31 00:07:56.000000000 +0200 -@@ -175,2 +175,3 @@ extern cCommands Commands; - extern cCommands RecordingCommands; -+extern cCommands TimerCommands; - extern cSVDRPhosts SVDRPhosts; -diff -ruN7p1 vdr-1.3.25-orig/i18n.c vdr-1.3.25/i18n.c ---- vdr-1.3.25-orig/i18n.c 2005-05-15 16:37:59.000000000 +0200 -+++ vdr-1.3.25/i18n.c 2005-05-31 00:07:56.000000000 +0200 -@@ -317,2 +317,23 @@ const tI18nPhrase Phrases[] = { - }, -+ { "Timer commands", -+ "Befehle für Timer", -+ "Ukazi za termine", -+ "Timer comandi", -+ "",// "Nederlands" -+ "",// "Português" -+ "Commandes de programmation", -+ "Timer kommandoer", -+ "Ajastinkomennot", -+ "",// "Polski" -+ "Comandos de programacion", -+ "",// "ÅëëçíéêÜ", // Greek -+ "Timer kommandon", -+ "Comenzi timer", -+ "",// "Magyar" -+ "Ordres de programació", -+ "",// "ÀãááÚØÙ", // Russian -+ "Naredbe za termine", -+ "",// "Eesti" -+ "",// "Dansk" -+ }, - { "Edit channel", -diff -ruN7p1 vdr-1.3.25-orig/menu.c vdr-1.3.25/menu.c ---- vdr-1.3.25-orig/menu.c 2005-05-16 15:59:03.000000000 +0200 -+++ vdr-1.3.25/menu.c 2005-05-31 00:12:31.000000000 +0200 -@@ -709,4 +709,16 @@ eOSState cMenuEditTimer::ProcessKey(eKey - --// --- cMenuTimerItem -------------------------------------------------------- -+// --- cMenuCommands --------------------------------------------------------- -+// declaration shifted so it can be used in cMenuTimers -+class cMenuCommands : public cOsdMenu { -+private: -+ cCommands *commands; -+ char *parameters; -+ eOSState Execute(void); -+public: -+ cMenuCommands(const char *Title, cCommands *Commands, const char *Parameters = NULL); -+ virtual ~cMenuCommands(); -+ virtual eOSState ProcessKey(eKeys Key); -+ }; - -+// --- cMenuTimerItem -------------------------------------------------------- - class cMenuTimerItem : public cOsdItem { -@@ -775,2 +787,3 @@ private: - cTimer *CurrentTimer(void); -+ eOSState Commands(eKeys Key = kNone); - public: -@@ -877,2 +890,49 @@ eOSState cMenuTimers::Summary(void) - -+#define CHECK_2PTR_NULL(x_,y_) ((x_)? ((y_)? y_:""):"") -+ -+eOSState cMenuTimers::Commands(eKeys Key) -+{ -+ if (HasSubMenu() || Count() == 0) -+ return osContinue; -+ cTimer *ti = CurrentTimer(); -+ if (ti) { -+ char *parameter = NULL; -+ const cEvent *pEvent = ti->Event(); -+ int iRecNumber=0; -+ -+ if(!pEvent) { -+ Timers.SetEvents(); -+ pEvent = ti->Event(); -+ } -+ if(pEvent) { -+// create a dummy recording to get the real filename -+ cRecording *rc_dummy = new cRecording(ti, pEvent); -+ Recordings.Load(); -+ cRecording *rc = Recordings.GetByName(rc_dummy->FileName()); -+ -+ delete rc_dummy; -+ if(rc) -+ iRecNumber=rc->Index() + 1; -+ } -+//Parameter format TimerNumber 'ChannelId' Start Stop 'Titel' 'Subtitel' 'file' RecNumer -+// 1 2 3 4 5 6 7 8 -+ asprintf(¶meter, "%d '%s' %d %d '%s' '%s' '%s' %d", ti->Index(), -+ *ti->Channel()->GetChannelID().ToString(), -+ (int)ti->StartTime(), -+ (int)ti->StopTime(), -+ CHECK_2PTR_NULL(pEvent, pEvent->Title()), -+ CHECK_2PTR_NULL(pEvent, pEvent->ShortText()), -+ ti->File(), -+ iRecNumber); -+ isyslog("timercmd: %s", parameter); -+ cMenuCommands *menu; -+ eOSState state = AddSubMenu(menu = new cMenuCommands(tr("Timer commands"), &TimerCommands, parameter)); -+ free(parameter); -+ if (Key != kNone) -+ state = menu->ProcessKey(Key); -+ return state; -+ } -+ return osContinue; -+} -+ - eOSState cMenuTimers::ProcessKey(eKeys Key) -@@ -893,2 +952,4 @@ eOSState cMenuTimers::ProcessKey(eKeys K - break; -+ case k1...k9: return Commands(Key); -+ case k0: return (TimerCommands.Count()? Commands():osContinue); - default: break; -@@ -1241,13 +1302,2 @@ eOSState cMenuSchedule::ProcessKey(eKeys - --class cMenuCommands : public cOsdMenu { --private: -- cCommands *commands; -- char *parameters; -- eOSState Execute(void); --public: -- cMenuCommands(const char *Title, cCommands *Commands, const char *Parameters = NULL); -- virtual ~cMenuCommands(); -- virtual eOSState ProcessKey(eKeys Key); -- }; -- - cMenuCommands::cMenuCommands(const char *Title, cCommands *Commands, const char *Parameters) -diff -ruN7p1 vdr-1.3.25-orig/vdr.c vdr-1.3.25/vdr.c ---- vdr-1.3.25-orig/vdr.c 2005-05-26 12:45:29.000000000 +0200 -+++ vdr-1.3.25/vdr.c 2005-05-31 00:07:56.000000000 +0200 -@@ -395,2 +395,3 @@ int main(int argc, char *argv[]) - RecordingCommands.Load(AddDirectory(ConfigDirectory, "reccmds.conf"), true) && -+ TimerCommands.Load(AddDirectory(ConfigDirectory, "timercmds.conf"), true) && - SVDRPhosts.Load(AddDirectory(ConfigDirectory, "svdrphosts.conf"), true) && diff --git a/patches/timercmd-0.1_1.5.12.diff b/patches/timercmd-0.1_1.5.12.diff deleted file mode 100644 index da79b9c..0000000 --- a/patches/timercmd-0.1_1.5.12.diff +++ /dev/null @@ -1,170 +0,0 @@ -diff -Nru vdr-1.5.12-orig/config.c vdr-1.5.12/config.c ---- vdr-1.5.12-orig/config.c 2007-10-06 16:28:58.000000000 +0200 -+++ vdr-1.5.12/config.c 2007-11-28 21:01:20.000000000 +0100 -@@ -126,6 +126,7 @@ - - cCommands Commands; - cCommands RecordingCommands; -+cCommands TimerCommands; - - // -- cSVDRPhosts ------------------------------------------------------------ - -diff -Nru vdr-1.5.12-orig/config.h vdr-1.5.12/config.h ---- vdr-1.5.12-orig/config.h 2007-11-10 14:38:19.000000000 +0100 -+++ vdr-1.5.12/config.h 2007-11-28 21:01:20.000000000 +0100 -@@ -168,6 +168,7 @@ - - extern cCommands Commands; - extern cCommands RecordingCommands; -+extern cCommands TimerCommands; - extern cSVDRPhosts SVDRPhosts; - - class cSetupLine : public cListObject { -diff -Nru vdr-1.5.12-orig/menu.c vdr-1.5.12/menu.c ---- vdr-1.5.12-orig/menu.c 2007-11-03 16:02:00.000000000 +0100 -+++ vdr-1.5.12/menu.c 2007-11-28 21:01:20.000000000 +0100 -@@ -738,8 +738,20 @@ - return state; - } - --// --- cMenuTimerItem -------------------------------------------------------- -+// --- cMenuCommands --------------------------------------------------------- -+// declaration shifted so it can be used in cMenuTimers -+class cMenuCommands : public cOsdMenu { -+private: -+ cCommands *commands; -+ char *parameters; -+ eOSState Execute(void); -+public: -+ cMenuCommands(const char *Title, cCommands *Commands, const char *Parameters = NULL); -+ virtual ~cMenuCommands(); -+ virtual eOSState ProcessKey(eKeys Key); -+ }; - -+// --- cMenuTimerItem -------------------------------------------------------- - class cMenuTimerItem : public cOsdItem { - private: - cTimer *timer; -@@ -804,6 +816,7 @@ - eOSState OnOff(void); - eOSState Info(void); - cTimer *CurrentTimer(void); -+ eOSState Commands(eKeys Key = kNone); - void SetHelpKeys(void); - public: - cMenuTimers(void); -@@ -920,6 +933,53 @@ - return osContinue; - } - -+#define CHECK_2PTR_NULL(x_,y_) ((x_)? ((y_)? y_:""):"") -+ -+eOSState cMenuTimers::Commands(eKeys Key) -+{ -+ if (HasSubMenu() || Count() == 0) -+ return osContinue; -+ cTimer *ti = CurrentTimer(); -+ if (ti) { -+ char *parameter = NULL; -+ const cEvent *pEvent = ti->Event(); -+ int iRecNumber=0; -+ -+ if(!pEvent) { -+ Timers.SetEvents(); -+ pEvent = ti->Event(); -+ } -+ if(pEvent) { -+// create a dummy recording to get the real filename -+ cRecording *rc_dummy = new cRecording(ti, pEvent); -+ Recordings.Load(); -+ cRecording *rc = Recordings.GetByName(rc_dummy->FileName()); -+ -+ delete rc_dummy; -+ if(rc) -+ iRecNumber=rc->Index() + 1; -+ } -+//Parameter format TimerNumber 'ChannelId' Start Stop 'Titel' 'Subtitel' 'file' RecNumer -+// 1 2 3 4 5 6 7 8 -+ asprintf(¶meter, "%d '%s' %d %d '%s' '%s' '%s' %d", ti->Index(), -+ *ti->Channel()->GetChannelID().ToString(), -+ (int)ti->StartTime(), -+ (int)ti->StopTime(), -+ CHECK_2PTR_NULL(pEvent, pEvent->Title()), -+ CHECK_2PTR_NULL(pEvent, pEvent->ShortText()), -+ ti->File(), -+ iRecNumber); -+ isyslog("timercmd: %s", parameter); -+ cMenuCommands *menu; -+ eOSState state = AddSubMenu(menu = new cMenuCommands(tr("Timer commands"), &TimerCommands, parameter)); -+ free(parameter); -+ if (Key != kNone) -+ state = menu->ProcessKey(Key); -+ return state; -+ } -+ return osContinue; -+} -+ - eOSState cMenuTimers::ProcessKey(eKeys Key) - { - int TimerNumber = HasSubMenu() ? Count() : -1; -@@ -933,6 +993,8 @@ - case kYellow: state = Delete(); break; - case kBlue: return Info(); - break; -+ case k1...k9: return Commands(Key); -+ case k0: return (TimerCommands.Count()? Commands():osContinue); - default: break; - } - } -@@ -1517,17 +1579,6 @@ - - // --- cMenuCommands --------------------------------------------------------- - --class cMenuCommands : public cOsdMenu { --private: -- cCommands *commands; -- char *parameters; -- eOSState Execute(void); --public: -- cMenuCommands(const char *Title, cCommands *Commands, const char *Parameters = NULL); -- virtual ~cMenuCommands(); -- virtual eOSState ProcessKey(eKeys Key); -- }; -- - cMenuCommands::cMenuCommands(const char *Title, cCommands *Commands, const char *Parameters) - :cOsdMenu(Title) - { - -diff -Nru vdr-1.5.12-orig/po/de_DE.po vdr-1.5.12/po/de_DE.po ---- vdr-1.5.12-orig/po/de_DE.po 2007-11-04 12:37:26.000000000 +0100 -+++ vdr-1.5.12/po/de_DE.po 2007-11-28 21:03:00.000000000 +0100 -@@ -7,7 +7,7 @@ - msgstr "" - "Project-Id-Version: VDR 1.5.7\n" - "Report-Msgid-Bugs-To: <vdr-bugs@cadsoft.de>\n" --"POT-Creation-Date: 2007-10-13 11:29+0200\n" -+"POT-Creation-Date: 2007-11-28 21:02+0100\n" - "PO-Revision-Date: 2007-08-12 14:17+0200\n" - "Last-Translator: Klaus Schmidinger <kls@cadsoft.de>\n" - "Language-Team: <vdr@linuxtv.org>\n" -@@ -375,6 +375,9 @@ - msgid "Timer still recording - really delete?" - msgstr "Timer zeichnet auf - trotzdem löschen?" - -+msgid "Timer commands" -+msgstr "Befehle für Timer" -+ - msgid "Event" - msgstr "Sendung" - -diff -Nru vdr-1.5.12-orig/vdr.c vdr-1.5.12/vdr.c ---- vdr-1.5.12-orig/vdr.c 2007-11-03 15:46:29.000000000 +0100 -+++ vdr-1.5.12/vdr.c 2007-11-28 21:01:20.000000000 +0100 -@@ -550,6 +550,7 @@ - Timers.Load(AddDirectory(ConfigDirectory, "timers.conf")) && - Commands.Load(AddDirectory(ConfigDirectory, "commands.conf"), true) && - RecordingCommands.Load(AddDirectory(ConfigDirectory, "reccmds.conf"), true) && -+ TimerCommands.Load(AddDirectory(ConfigDirectory, "timercmds.conf"), true) && - SVDRPhosts.Load(AddDirectory(ConfigDirectory, "svdrphosts.conf"), true) && - Keys.Load(AddDirectory(ConfigDirectory, "remote.conf")) && - KeyMacros.Load(AddDirectory(ConfigDirectory, "keymacros.conf"), true) diff --git a/patches/vdr-1.5.11-progressbar-support-0.0.1.diff b/patches/vdr-1.5.11-progressbar-support-0.0.1.diff deleted file mode 100644 index 17cb3f3..0000000 --- a/patches/vdr-1.5.11-progressbar-support-0.0.1.diff +++ /dev/null @@ -1,113 +0,0 @@ -diff -Nru vdr-1.5.11-orig/skinclassic.c vdr-1.5.11-progressbar/skinclassic.c ---- vdr-1.5.11-orig/skinclassic.c 2007-07-29 14:35:03.000000000 +0200 -+++ vdr-1.5.11-progressbar/skinclassic.c 2007-11-12 18:46:54.000000000 +0100 -@@ -295,13 +295,51 @@ - const cFont *font = cFont::GetFont(fontOsd); - for (int i = 0; i < MaxTabs; i++) { - const char *s = GetTabbedText(Text, i); -+ - if (s) { -- int xt = x0 + Tab(i); -- osd->DrawText(xt, y, s, ColorFg, ColorBg, font, x1 - xt); -- } -- if (!Tab(i + 1)) -- break; -+ bool isprogressbar = false; -+ int now = 0, total = 0; -+ // check if progress bar: "[||||||| ]" -+ if ((strlen(s) > 5 && s[0] == '[' && s[strlen(s) - 1] == ']')) { -+ const char *p = s + 1; -+ // update status -+ isprogressbar = true; -+ for (; *p != ']'; ++p) { -+ // check if progressbar characters -+ if (*p == ' ' || *p == '|') { -+ // update counters -+ ++total; -+ if (*p == '|') -+ ++now; -+ } else { -+ // wrong character detected; not a progressbar -+ isprogressbar = false; -+ break; -+ } -+ } -+ } -+ int xt = x0 + Tab(i); -+ if (isprogressbar) { -+ // define x coordinates of progressbar -+ int px0 = xt; -+ int px1 = (Tab(i + 1)?Tab(i+1):x1) - 5; -+ int px = px0 + max((int)((float) now * (float) (px1 - px0) / (float) total), 1); -+ // define y coordinates of progressbar -+ int py0 = y + 4; -+ int py1 = y + lineHeight - 4; -+ // draw background -+ osd->DrawRectangle(px0, y, (Tab(i + 1)?Tab(i+1):x1) - 1, y + lineHeight - 1, ColorBg); -+ // draw progressbar -+ osd->DrawRectangle(px0, py0, px, py1, ColorFg); -+ osd->DrawRectangle(px + 1, py0, px1, py0 + 1, ColorFg); -+ osd->DrawRectangle(px + 1, py1 - 1, px1, py1, ColorFg); -+ osd->DrawRectangle(px1 - 1, py0, px1, py1, ColorFg); -+ } else -+ osd->DrawText(xt, y, s, ColorFg, ColorBg, font, x1 - xt); - } -+ if (!Tab(i + 1)) -+ break; -+ } - SetEditableWidth(x1 - x0 - Tab(1)); - } - -diff -Nru vdr-1.5.11-orig/skinsttng.c vdr-1.5.11-progressbar/skinsttng.c ---- vdr-1.5.11-orig/skinsttng.c 2007-06-17 15:51:56.000000000 +0200 -+++ vdr-1.5.11-progressbar/skinsttng.c 2007-11-12 18:47:01.000000000 +0100 -@@ -545,9 +545,46 @@ - for (int i = 0; i < MaxTabs; i++) { - const char *s = GetTabbedText(Text, i); - if (s) { -- int xt = x3 + 5 + Tab(i); -- osd->DrawText(xt, y, s, ColorFg, ColorBg, font, x4 - xt); -- } -+ bool isprogressbar = false; -+ int now = 0, total = 0; -+ // check if progress bar: "[||||||| ]" -+ if ((strlen(s) > 5 && s[0] == '[' && s[strlen(s) - 1] == ']')) { -+ const char *p = s + 1; -+ // update status -+ isprogressbar = true; -+ for (; *p != ']'; ++p) { -+ // check if progressbar characters -+ if (*p == ' ' || *p == '|') { -+ // update counters -+ ++total; -+ if (*p == '|') -+ ++now; -+ } else { -+ // wrong character detected; not a progressbar -+ isprogressbar = false; -+ break; -+ } -+ } -+ } -+ int xt = x3 + 5 + Tab(i); -+ if (isprogressbar) { -+ // define x coordinates of progressbar -+ int px0 = xt; -+ int px1 = x3 + (Tab(i + 1)?Tab(i + 1):x4-x3-5) - 1; -+ int px = px0 + max((int)((float) now * (float) (px1 - px0) / (float) total), 1); -+ // define y coordinates of progressbar -+ int py0 = y + 4; -+ int py1 = y + lineHeight - 4; -+ // draw background -+ osd->DrawRectangle(px0, y, (Tab(i + 1)?Tab(i + 1):x4-x3-5) - 1, y + lineHeight - 1, ColorBg); -+ // draw progressbar -+ osd->DrawRectangle(px0, py0, px, py1, ColorFg); -+ osd->DrawRectangle(px + 1, py0, px1, py0 + 1, ColorFg); -+ osd->DrawRectangle(px + 1, py1 - 1, px1, py1, ColorFg); -+ osd->DrawRectangle(px1 - 1, py0, px1, py1, ColorFg); -+ } else -+ osd->DrawText(xt, y, s, ColorFg, ColorBg, font, x4 - xt); -+ } - if (!Tab(i + 1)) - break; - } |