From d008680ad78832701d59d54733d302c0287bc879 Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Fri, 27 Jul 2001 11:51:42 +0200 Subject: Made the width and height of the OSD configurable --- interface.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'interface.c') diff --git a/interface.c b/interface.c index 55129341..572a41b8 100644 --- a/interface.c +++ b/interface.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: interface.c 1.37 2001/07/22 12:26:28 kls Exp $ + * $Id: interface.c 1.38 2001/07/27 11:39:53 kls Exp $ */ #include "interface.h" @@ -44,8 +44,13 @@ cInterface::~cInterface() void cInterface::Open(int NumCols, int NumLines) { - if (!open++) + if (!open++) { + if (NumCols == 0) + NumCols = Setup.OSDwidth; + if (NumLines == 0) + NumLines = Setup.OSDheight; cDvbApi::PrimaryDvbApi->Open(width = NumCols, height = NumLines); + } } void cInterface::Close(void) @@ -289,7 +294,7 @@ void cInterface::Status(const char *s, eDvbColor FgColor, eDvbColor BgColor) void cInterface::Info(const char *s) { - Open(MenuColumns, -1); + Open(Setup.OSDwidth, -1); isyslog(LOG_INFO, "info: %s", s); Status(s, clrWhite, clrGreen); Wait(); @@ -299,7 +304,7 @@ void cInterface::Info(const char *s) void cInterface::Error(const char *s) { - Open(MenuColumns, -1); + Open(Setup.OSDwidth, -1); esyslog(LOG_ERR, "ERROR: %s", s); Status(s, clrWhite, clrRed); Wait(); -- cgit v1.2.3