diff options
author | Klaus Schmidinger <kls (at) cadsoft (dot) de> | 2000-03-11 18:00:00 +0100 |
---|---|---|
committer | Klaus Schmidinger <kls (at) cadsoft (dot) de> | 2000-03-11 18:00:00 +0100 |
commit | 6feebe674c09b65e43012bf439c201cfb65aa82c (patch) | |
tree | 85cf564cd0f48e44431a93ea2f22bba7fc924e98 /osd.h | |
parent | c475c637aba78366763cb122673ff836dd9e7e85 (diff) | |
download | vdr-patch-lnbsharing-6feebe674c09b65e43012bf439c201cfb65aa82c.tar.gz vdr-patch-lnbsharing-6feebe674c09b65e43012bf439c201cfb65aa82c.tar.bz2 |
Version 0.02vdr_osm-0.02
- Fixed compilation with only DEBUG_REMOTE=1.
- Menus now use colors.
- Support for "Red", "Green", "Yellow", "Blue" buttons.
- Channels and Timers can now be added, deleted and moved.
- Basic record/play file handling support (no actual record/playback yet).
Diffstat (limited to 'osd.h')
-rw-r--r-- | osd.h | 42 |
1 files changed, 25 insertions, 17 deletions
@@ -4,7 +4,7 @@ * See the main source file 'osm.c' for copyright information and * how to reach the author. * - * $Id: osd.h 1.1 2000/02/19 13:36:48 kls Exp $ + * $Id: osd.h 1.2 2000/03/05 11:33:11 kls Exp $ */ #ifndef __OSD_H @@ -16,53 +16,61 @@ #define MAXOSDITEMS 9 -enum eOSStatus { osUnknown, - osContinue, - osProcessed, - osChannels, - osTimer, - osRecordings, - osBack, - osEnd, - }; +enum eOSState { osUnknown, + osContinue, + osProcessed, + osChannels, + osTimer, + osRecordings, + osBack, + osEnd, + }; class cOsdItem : public cListObject { private: char *text; int offset; - eOSStatus status; + eOSState state; protected: bool fresh; public: - cOsdItem(eOSStatus Status = osUnknown); - cOsdItem(char *Text, eOSStatus Status = osUnknown); + cOsdItem(eOSState State = osUnknown); + cOsdItem(char *Text, eOSState State = osUnknown); virtual ~cOsdItem(); void SetText(char *Text, bool Copy = true); char *Text(void) { return text; } void Display(int Offset = -1, bool Current = false); virtual void Set(void) {} - virtual eOSStatus ProcessKey(eKeys Key); + virtual eOSState ProcessKey(eKeys Key); }; class cOsdMenu : public cList<cOsdItem> { private: char *title; int cols[cInterface::MaxCols]; - int first, current, count; + int first, current, marked; cOsdMenu *subMenu; + const char *helpRed, *helpGreen, *helpYellow, *helpBlue; + const char *status; protected: + bool visible; void RefreshCurrent(void); void DisplayCurrent(bool Current); void CursorUp(void); void CursorDown(void); - eOSStatus AddSubMenu(cOsdMenu *SubMenu); + void Mark(void); + eOSState AddSubMenu(cOsdMenu *SubMenu); + bool HasSubMenu(void) { return subMenu; } + void SetStatus(const char *s); + void SetHelp(const char *Red, const char *Green = NULL, const char *Yellow = NULL, const char *Blue = NULL); + virtual void Del(int Index); public: cOsdMenu(char *Title, int c0 = 0, int c1 = 0, int c2 = 0, int c3 = 0, int c4 = 0); virtual ~cOsdMenu(); int Current(void) { return current; } void Add(cOsdItem *Item, bool Current = false); void Display(void); - virtual eOSStatus ProcessKey(eKeys Key); + virtual eOSState ProcessKey(eKeys Key); }; #endif //__OSD_H |