diff options
author | Klaus Schmidinger <vdr@tvdr.de> | 2005-05-16 14:45:11 +0200 |
---|---|---|
committer | Klaus Schmidinger <vdr@tvdr.de> | 2005-05-16 14:45:11 +0200 |
commit | b0583e5373e10119fd88d935cdded1e153101e22 (patch) | |
tree | 2281fe1f09492c8a528e48356571776ec7401324 /PLUGINS/src/skincurses | |
parent | 6e274dfeef1987bebfa2d662fc40e03bbad4951f (diff) | |
download | vdr-b0583e5373e10119fd88d935cdded1e153101e22.tar.gz vdr-b0583e5373e10119fd88d935cdded1e153101e22.tar.bz2 |
Switched from 'summary.vdr' to 'info.vdr'
Diffstat (limited to 'PLUGINS/src/skincurses')
-rw-r--r-- | PLUGINS/src/skincurses/HISTORY | 4 | ||||
-rw-r--r-- | PLUGINS/src/skincurses/skincurses.c | 29 |
2 files changed, 30 insertions, 3 deletions
diff --git a/PLUGINS/src/skincurses/HISTORY b/PLUGINS/src/skincurses/HISTORY index 8ba4ae4e..33119f4a 100644 --- a/PLUGINS/src/skincurses/HISTORY +++ b/PLUGINS/src/skincurses/HISTORY @@ -13,3 +13,7 @@ VDR Plugin 'skincurses' Revision History - Made several functions threadsafe. - New audio track display. + +2005-05-16: Version 0.0.4 + +- New "recording info" display. diff --git a/PLUGINS/src/skincurses/skincurses.c b/PLUGINS/src/skincurses/skincurses.c index a1c59540..ad1a26b4 100644 --- a/PLUGINS/src/skincurses/skincurses.c +++ b/PLUGINS/src/skincurses/skincurses.c @@ -3,7 +3,7 @@ * * See the README file for copyright information and how to reach the author. * - * $Id: skincurses.c 1.5 2005/01/09 11:56:26 kls Exp $ + * $Id: skincurses.c 1.6 2005/05/16 10:45:12 kls Exp $ */ #include <ncurses.h> @@ -11,7 +11,7 @@ #include <vdr/plugin.h> #include <vdr/skins.h> -static const char *VERSION = "0.0.3"; +static const char *VERSION = "0.0.4"; static const char *DESCRIPTION = "A text only skin"; static const char *MAINMENUENTRY = NULL; @@ -407,7 +407,30 @@ void cSkinCursesDisplayMenu::SetEvent(const cEvent *Event) void cSkinCursesDisplayMenu::SetRecording(const cRecording *Recording) { - SetText(Recording->Summary(), false); //TODO + if (!Recording) + return; + const cRecordingInfo *Info = Recording->Info(); + int y = 2; + cTextScroller ts; + char t[32]; + snprintf(t, sizeof(t), "%s %s", *DateString(Recording->start), *TimeString(Recording->start)); + ts.Set(osd, 0, y, OsdWidth, OsdHeight - y - 2, t, &Font, clrYellow, clrBackground); + y += ts.Height(); + y += 1; + const char *Title = Info->Title(); + if (isempty(Title)) + Title = Recording->Name(); + ts.Set(osd, 0, y, OsdWidth, OsdHeight - y - 2, Title, &Font, clrCyan, clrBackground); + y += ts.Height(); + if (!isempty(Info->ShortText())) { + ts.Set(osd, 0, y, OsdWidth, OsdHeight - y - 2, Info->ShortText(), &Font, clrYellow, clrBackground); + y += ts.Height(); + } + y += 1; + if (!isempty(Info->Description())) { + textScroller.Set(osd, 0, y, OsdWidth - 2, OsdHeight - y - 2, Info->Description(), &Font, clrCyan, clrBackground); + SetScrollbar(); + } } void cSkinCursesDisplayMenu::SetText(const char *Text, bool FixedFont) |