summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2001-07-27 10:59:50 +0200
committerKlaus Schmidinger <vdr@tvdr.de>2001-07-27 10:59:50 +0200
commit81919a6647b6c02e8ea368ae0c88db367341c769 (patch)
tree302e921bc3ca3794512fe1b4db260e5eae13f0dd
parent697b3898729f2d10bf6653adc04cdf85152d0bff (diff)
downloadvdr-81919a6647b6c02e8ea368ae0c88db367341c769.tar.gz
vdr-81919a6647b6c02e8ea368ae0c88db367341c769.tar.bz2
Made the position of the channel display configurable
-rw-r--r--CONTRIBUTORS1
-rw-r--r--HISTORY2
-rw-r--r--MANUAL4
-rw-r--r--config.c5
-rw-r--r--config.h3
-rw-r--r--dvbapi.c14
-rw-r--r--i18n.c26
-rw-r--r--menu.c7
8 files changed, 49 insertions, 13 deletions
diff --git a/CONTRIBUTORS b/CONTRIBUTORS
index 7dbbc834..45353b3b 100644
--- a/CONTRIBUTORS
+++ b/CONTRIBUTORS
@@ -97,6 +97,7 @@ Jřrgen Tvedt <pjtvedt@online.no>
Stefan Huelswitt <huels@iname.com>
for fixing the repeat function with LIRC
+ for making the position of the channel display configurable
Ulrich Röder <dynamite@efr-net.de>
for pointing out that there are channels that have a symbol rate higher than
diff --git a/HISTORY b/HISTORY
index 899d3e41..76e90ef6 100644
--- a/HISTORY
+++ b/HISTORY
@@ -580,3 +580,5 @@ Video Disk Recorder Revision History
- Fixed repeat function with LIRC (thanks to Stefan Huelswitt).
- Increased the upper limit for the symbol rate to 30000 (thanks to Ulrich
Röder).
+- Made the position of the channel display configurable (thanks to Stefan
+ Huelswitt).
diff --git a/MANUAL b/MANUAL
index 4d5a5768..2aa4a415 100644
--- a/MANUAL
+++ b/MANUAL
@@ -365,6 +365,10 @@ Video Disk Recorder User's Manual
0 = 4:3
1 = 16:9
+ ChannelInfoPos = 0 The position of the channel info window in the OSD.
+ 0 = bottom
+ 1 = top
+
* Executing system commands
The "Main" menu option "Commands" allows you to execute any system commands
diff --git a/config.c b/config.c
index 334719ed..e5d80767 100644
--- a/config.c
+++ b/config.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: config.c 1.49 2001/07/22 14:15:25 kls Exp $
+ * $Id: config.c 1.50 2001/07/27 10:43:40 kls Exp $
*/
#include "config.h"
@@ -773,6 +773,7 @@ cSetup::cSetup(void)
DefaultPriority = 50;
DefaultLifetime = 50;
VideoFormat = VIDEO_FORMAT_4_3;
+ ChannelInfoPos = 0;
CurrentChannel = -1;
}
@@ -799,6 +800,7 @@ bool cSetup::Parse(char *s)
else if (!strcasecmp(Name, "DefaultPriority")) DefaultPriority = atoi(Value);
else if (!strcasecmp(Name, "DefaultLifetime")) DefaultLifetime = atoi(Value);
else if (!strcasecmp(Name, "VideoFormat")) VideoFormat = atoi(Value);
+ else if (!strcasecmp(Name, "ChannelInfoPos")) ChannelInfoPos = atoi(Value);
else if (!strcasecmp(Name, "CurrentChannel")) CurrentChannel = atoi(Value);
else
return false;
@@ -860,6 +862,7 @@ bool cSetup::Save(const char *FileName)
fprintf(f, "DefaultPriority = %d\n", DefaultPriority);
fprintf(f, "DefaultLifetime = %d\n", DefaultLifetime);
fprintf(f, "VideoFormat = %d\n", VideoFormat);
+ fprintf(f, "ChannelInfoPos = %d\n", ChannelInfoPos);
fprintf(f, "CurrentChannel = %d\n", CurrentChannel);
f.Close();
isyslog(LOG_INFO, "saved setup to %s", FileName);
diff --git a/config.h b/config.h
index 4f6f6e6b..ca4782bf 100644
--- a/config.h
+++ b/config.h
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: config.h 1.52 2001/07/24 15:58:39 kls Exp $
+ * $Id: config.h 1.53 2001/07/27 10:42:30 kls Exp $
*/
#ifndef __CONFIG_H
@@ -277,6 +277,7 @@ public:
int PrimaryLimit;
int DefaultPriority, DefaultLifetime;
int VideoFormat;
+ int ChannelInfoPos;
int CurrentChannel;
cSetup(void);
bool Load(const char *FileName);
diff --git a/dvbapi.c b/dvbapi.c
index fd37773b..f322afb0 100644
--- a/dvbapi.c
+++ b/dvbapi.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: dvbapi.c 1.87 2001/07/22 12:18:29 kls Exp $
+ * $Id: dvbapi.c 1.88 2001/07/27 10:49:51 kls Exp $
*/
#include "dvbapi.h"
@@ -1875,17 +1875,17 @@ void cDvbApi::Open(int w, int h)
//XXX
osd = new cDvbOsd(fd_osd, x, y);
//XXX TODO this should be transferred to the places where the individual windows are requested (there's too much detailed knowledge here!)
- if (d == 0) { //XXX full menu
- osd->Create(0, 0, w, lineHeight, 2);
- osd->Create(0, lineHeight, w, (MenuLines - 3) * lineHeight, 2, true, clrBackground, clrCyan, clrWhite, clrBlack);
- osd->Create(0, (MenuLines - 2) * lineHeight, w, 2 * lineHeight, 4);
- }
- else if (h / lineHeight == 5) { //XXX channel display
+ if (h / lineHeight == 5) { //XXX channel display
osd->Create(0, 0, w, h, 4);
}
else if (h / lineHeight == 1) { //XXX info display
osd->Create(0, 0, w, h, 4);
}
+ else if (d == 0) { //XXX full menu
+ osd->Create(0, 0, w, lineHeight, 2);
+ osd->Create(0, lineHeight, w, (MenuLines - 3) * lineHeight, 2, true, clrBackground, clrCyan, clrWhite, clrBlack);
+ osd->Create(0, (MenuLines - 2) * lineHeight, w, 2 * lineHeight, 4);
+ }
else { //XXX progress display
/*XXX
osd->Create(0, 0, w, lineHeight, 1);
diff --git a/i18n.c b/i18n.c
index d1ebc59b..bbe98098 100644
--- a/i18n.c
+++ b/i18n.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: i18n.c 1.23 2001/07/24 16:00:54 kls Exp $
+ * $Id: i18n.c 1.24 2001/07/27 10:55:52 kls Exp $
*
* Slovenian translations provided by Miha Setina <mihasetina@softhome.net>
* Italian translations provided by Alberto Carraro <bertocar@tin.it>
@@ -794,6 +794,14 @@ const tPhrase Phrases[] = {
"Format vidéo",
"TV Format",
},
+ { "ChannelInfoPos",
+ "Kanal Info Position",
+ "", // TODO
+ "", // TODO
+ "", // TODO
+ "", // TODO
+ "", // TODO
+ },
// The days of the week:
{ "MTWTFSS",
"MDMDFSS",
@@ -1041,6 +1049,22 @@ const tPhrase Phrases[] = {
"non",
"nei",
},
+ { "top",
+ "oben",
+ "", // TODO
+ "", // TODO
+ "", // TODO
+ "", // TODO
+ "", // TODO
+ },
+ { "bottom",
+ "unten",
+ "", // TODO
+ "", // TODO
+ "", // TODO
+ "", // TODO
+ "", // TODO
+ },
{ " Stop replaying", // note the leading blank!
" Wiedergabe beenden",
" Prekini ponavljanje",
diff --git a/menu.c b/menu.c
index accc14a7..769165d6 100644
--- a/menu.c
+++ b/menu.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: menu.c 1.81 2001/07/27 10:26:22 kls Exp $
+ * $Id: menu.c 1.82 2001/07/27 10:54:21 kls Exp $
*/
#include "menu.h"
@@ -1626,6 +1626,7 @@ void cMenuSetup::Set(void)
Add(new cMenuEditIntItem( tr("DefaultPriority"), &data.DefaultPriority, 0, MAXPRIORITY));
Add(new cMenuEditIntItem( tr("DefaultLifetime"), &data.DefaultLifetime, 0, MAXLIFETIME));
Add(new cMenuEditBoolItem(tr("VideoFormat"), &data.VideoFormat, "4:3", "16:9"));
+ Add(new cMenuEditBoolItem(tr("ChannelInfoPos"), &data.ChannelInfoPos, tr("bottom"), tr("top")));
}
eOSState cMenuSetup::ProcessKey(eKeys Key)
@@ -1802,7 +1803,7 @@ cDisplayChannel::cDisplayChannel(int Number, bool Switched, bool Group)
lines = 0;
oldNumber = number = 0;
cChannel *channel = Group ? Channels.Get(Number) : Channels.GetByNumber(Number);
- Interface->Open(MenuColumns, -5);
+ Interface->Open(MenuColumns, Setup.ChannelInfoPos ? 5 : -5);
if (channel) {
DisplayChannel(channel);
DisplayInfo();
@@ -1816,7 +1817,7 @@ cDisplayChannel::cDisplayChannel(eKeys FirstKey)
oldNumber = cDvbApi::CurrentChannel();
number = 0;
lastTime = time_ms();
- Interface->Open(MenuColumns, -5);
+ Interface->Open(MenuColumns, Setup.ChannelInfoPos ? 5 : -5);
ProcessKey(FirstKey);
}