2000-02-19 13:36:48 +01:00
|
|
|
/*
|
|
|
|
* menu.h: The actual menu implementations
|
|
|
|
*
|
2000-04-24 09:46:05 +02:00
|
|
|
* See the main source file 'vdr.c' for copyright information and
|
2000-02-19 13:36:48 +01:00
|
|
|
* how to reach the author.
|
|
|
|
*
|
2000-09-10 14:56:18 +02:00
|
|
|
* $Id: menu.h 1.10 2000/09/10 14:42:20 kls Exp $
|
2000-02-19 13:36:48 +01:00
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef _MENU_H
|
|
|
|
#define _MENU_H
|
|
|
|
|
2000-05-01 16:29:46 +02:00
|
|
|
#define _GNU_SOURCE
|
|
|
|
|
|
|
|
#include "dvbapi.h"
|
2000-02-19 13:36:48 +01:00
|
|
|
#include "osd.h"
|
|
|
|
|
|
|
|
class cMenuMain : public cOsdMenu {
|
2000-05-01 16:29:46 +02:00
|
|
|
private:
|
|
|
|
time_t lastActivity;
|
2000-02-19 13:36:48 +01:00
|
|
|
public:
|
2000-05-01 16:29:46 +02:00
|
|
|
cMenuMain(bool Replaying);
|
2000-03-11 11:22:37 +01:00
|
|
|
virtual eOSState ProcessKey(eKeys Key);
|
2000-02-19 13:36:48 +01:00
|
|
|
};
|
|
|
|
|
2000-09-10 14:56:18 +02:00
|
|
|
class cDirectChannelSelect : public cOsdBase {
|
|
|
|
private:
|
|
|
|
int oldNumber;
|
|
|
|
int number;
|
|
|
|
int lastTime;
|
|
|
|
public:
|
|
|
|
cDirectChannelSelect(eKeys FirstKey);
|
|
|
|
virtual ~cDirectChannelSelect();
|
|
|
|
virtual eOSState ProcessKey(eKeys Key);
|
|
|
|
};
|
|
|
|
|
2000-05-01 16:29:46 +02:00
|
|
|
class cRecordControl {
|
2000-04-30 10:22:13 +02:00
|
|
|
private:
|
2000-05-01 16:29:46 +02:00
|
|
|
cDvbApi *dvbApi;
|
2000-04-30 10:22:13 +02:00
|
|
|
cTimer *timer;
|
2000-05-01 16:29:46 +02:00
|
|
|
char *instantId;
|
2000-04-30 10:22:13 +02:00
|
|
|
public:
|
2000-05-01 16:29:46 +02:00
|
|
|
cRecordControl(cDvbApi *DvbApi, cTimer *Timer = NULL);
|
2000-04-30 10:22:13 +02:00
|
|
|
virtual ~cRecordControl();
|
2000-05-01 16:29:46 +02:00
|
|
|
bool Process(void);
|
2000-04-30 11:15:16 +02:00
|
|
|
void Stop(bool KeepInstant = false);
|
2000-05-01 16:29:46 +02:00
|
|
|
bool IsInstant(void) { return instantId; }
|
|
|
|
const char *InstantId(void) { return instantId; }
|
|
|
|
};
|
|
|
|
|
|
|
|
class cRecordControls {
|
|
|
|
private:
|
|
|
|
static cRecordControl *RecordControls[MAXDVBAPI];
|
|
|
|
public:
|
|
|
|
static bool Start(cTimer *Timer = NULL);
|
|
|
|
static void Stop(const char *InstantId);
|
|
|
|
static const char *GetInstantId(const char *LastInstantId);
|
|
|
|
static void Process(void);
|
2000-04-30 10:22:13 +02:00
|
|
|
};
|
|
|
|
|
2000-04-29 15:57:42 +02:00
|
|
|
class cReplayControl : public cOsdBase {
|
2000-04-24 15:32:11 +02:00
|
|
|
private:
|
2000-05-01 16:29:46 +02:00
|
|
|
cDvbApi *dvbApi;
|
2000-04-29 15:57:42 +02:00
|
|
|
bool visible, shown;
|
|
|
|
void Show(void);
|
|
|
|
void Hide(void);
|
|
|
|
static char *fileName;
|
|
|
|
static char *title;
|
2000-04-23 15:38:16 +02:00
|
|
|
public:
|
2000-04-29 15:57:42 +02:00
|
|
|
cReplayControl(void);
|
|
|
|
virtual ~cReplayControl();
|
|
|
|
virtual eOSState ProcessKey(eKeys Key);
|
|
|
|
bool Visible(void) { return visible; }
|
|
|
|
static void SetRecording(const char *FileName, const char *Title);
|
2000-04-23 15:38:16 +02:00
|
|
|
};
|
|
|
|
|
2000-02-19 13:36:48 +01:00
|
|
|
#endif //_MENU_H
|