36 #define MAXWAIT4EPGINFO 3 // seconds
37 #define MODETIMEOUT 3 // seconds
38 #define NEWTIMERLIMIT 120 // seconds until the start time of a new timer created from the Schedule menu,
41 #define DEFERTIMER 60 // seconds by which a timer is deferred in case of problems
43 #define MAXRECORDCONTROLS (MAXDEVICES * MAXRECEIVERS)
44 #define MAXINSTANTRECTIME (24 * 60 - 1) // 23:59 hours
45 #define MAXWAITFORCAMMENU 10 // seconds to wait for the CAM menu to open
46 #define CAMMENURETYTIMEOUT 3 // seconds after which opening the CAM menu is retried
47 #define CAMRESPONSETIMEOUT 5 // seconds to wait for a response from a CAM
48 #define MINFREEDISK 300 // minimum free disk space (in MB) required to start recording
49 #define NODISKSPACEDELTA 300 // seconds between "Not enough disk space to start recording!" messages
50 #define MAXCHNAMWIDTH 16 // maximum number of characters of channels' short names shown in schedules menus
52 #define CHNUMWIDTH (numdigits(Channels.MaxNumber()) + 1)
53 #define CHNAMWIDTH (min(MAXCHNAMWIDTH, Channels.MaxShortChannelNameLength() + 1))
59 virtual void Set(
void);
102 virtual void Set(
void);
286 virtual void Set(
void);
317 const cEvent *Event = NULL;
327 Event ?
'(' :
' ', Event ? Event->
Title() :
"", Event ?
')' :
' ');
330 Event ?
'(' :
' ', Event ? Event->
Title() :
"", Event ?
')' :
' ');
340 DisplayMenu->
SetItem(
Text(), Index, Current, Selectable);
345 #define CHANNELNUMBERTIMEOUT 1000 //ms
360 virtual void Move(
int From,
int To);
392 if (channel == currentChannel)
399 SetHelp(
tr(
"Button$Edit"),
tr(
"Button$New"),
tr(
"Button$Delete"),
tr(
"Button$Mark"));
431 if (!ci->Channel()->GroupSep() && ci->Channel()->Number() ==
number) {
476 int DeletedChannel = channel->
Number();
483 if (CurrentChannel && channel == CurrentChannel) {
488 CurrentChannelNr = 0;
494 isyslog(
"channel %d deleted", DeletedChannel);
495 if (CurrentChannel && CurrentChannel->
Number() != CurrentChannelNr) {
512 if (FromChannel && ToChannel) {
513 int FromNumber = FromChannel->
Number();
514 int ToNumber = ToChannel->
Number();
519 isyslog(
"channel %d moved to %d", FromNumber, ToNumber);
520 if (CurrentChannel && CurrentChannel->
Number() != CurrentChannelNr) {
580 text = Text ? strdup(Text) : NULL;
653 :
cOsdMenu(Folder ?
tr(
"Edit folder") :
tr(
"New folder"), 12)
686 if (strcmp(Folder->Text(),
name) == 0) {
691 char *p = strpbrk(
name,
"\\{}#~");
768 Add(FolderItem, CurrentFolder ? strcmp(Folder->Text(), CurrentFolder) == 0 :
false);
780 if (strncmp(Folder->Folder()->Text(), Path, p - Path) == 0) {
782 if (Folder->Folder()->SubItems())
954 memmove(
data.
file, p, strlen(p) + 1);
1021 virtual void Set(
void);
1050 localtime_r(&Day, &tm_r);
1052 strftime(buffer,
sizeof(buffer),
"%Y%m%d", &tm_r);
1061 char diskStatusString[2] = {
diskStatus, 0 };
1063 csc.
Convert(diskStatusString),
1067 *name && **name ?
" " :
"",
1079 DisplayMenu->
SetItem(
Text(), Index, Current, Selectable);
1161 timer->SetEventFromSchedule();
1179 return item ? item->
Timer() : NULL;
1184 int NewHelpKeys = 0;
1256 #define CHECK_2PTR_NULL(x_,y_) ((x_)? ((y_)? y_:""):"")
1264 char *parameter = NULL;
1270 pEvent = ti->
Event();
1280 iRecNumber=rc->
Index() + 1;
1284 asprintf(¶meter,
"%d '%s' %d %d '%s' '%s' '%s' %d", ti->
Index(),
1292 isyslog(
"timercmd: %s", parameter);
1308 if (ti && ti->
Event())
1319 int freeMB, freeMinutes, runshortMinutes;
1321 freeMinutes = int(
double(freeMB) * 1.1 / 25.75);
1322 runshortMinutes = freeMinutes / 5;
1332 for (entry = entries.
First(); entry; entry = entries.
Next(entry))
1336 for (entry = entries.
First(); entry; entry = entries.
Next(entry))
1346 for (entry = entries.
First(); entry; entry = entries.
Next(entry)) {
1350 status = freeMinutes > runshortMinutes ?
'+' : freeMinutes > 0 ? 177 :
'-';
1353 #ifdef DEBUG_TIMER_INFO
1354 dsyslog(
"timer-info: %c | %d | %s | %s | %3d | %+5d -> %+5d",
1357 entry->
active() ?
"aktiv " :
"n.akt.",
1358 entry->
repTimer() ? entry->
isDummy() ?
" dummy " :
"mehrmalig" :
"einmalig ",
1383 state =
OnOff();
break;
1421 SetHelp(TimerMatch ==
tmFull ?
tr(
"Button$Timer") :
tr(
"Button$Record"), NULL, NULL, CanSwitch ?
tr(
"Button$Switch") : NULL);
1482 bool Update(
bool Force =
false);
1512 bool result =
false;
1518 char v =
event->Vps() && (
event->Vps() -
event->StartTime()) ?
'V' :
' ';
1519 char r =
event->SeenWithin(30) &&
event->IsRunning() ?
'*' :
' ';
1521 cString eds =
event->GetDateString();
1523 buffer =
cString::sprintf(
"%d\t%.*s\t%.*s\t%s\t%c%c%c\t%s",
channel->
Number(),
Utf8SymChars(csn, 999), csn,
Utf8SymChars(eds, 6), *eds, *
event->GetTimeString(), t, v, r,
event->Title());
1537 DisplayMenu->
SetItem(
Text(), Index, Current, Selectable);
1573 if (!Channel->GroupSep()) {
1589 bool result =
false;
1602 int NewHelpKeys = 0;
1610 const char *Red[] = { NULL,
tr(
"Button$Record"),
tr(
"Button$Timer") };
1611 SetHelp(Red[NewHelpKeys],
now ?
tr(
"Button$Next") :
tr(
"Button$Now"),
tr(
"Button$Schedule"),
tr(
"Button$Switch"));
1696 if (HadSubMenu &&
Update())
1764 if (ev->EndTime() > now || ev == PresentEvent)
1781 if ((ev->EndTime() > now || ev == Event) && !strcmp(ev->Title(), Event->
Title()))
1799 if ((ev->EndTime() > now || ev == Event) && !strcmp(ev->Title(), Event->
Title()))
1818 if (ev->EndTime() > now || ev == Event)
1828 bool result =
false;
1841 int NewHelpKeys = 0;
1849 const char *Red[] = { NULL,
tr(
"Button$Record"),
tr(
"Button$Timer") };
1850 SetHelp(Red[NewHelpKeys],
tr(
"Button$Now"),
tr(
"Button$Next"));
1860 const cEvent *Event = NULL;
1862 Event = CurrentItem->
event;
1940 ChannelNr = channel->
Number();
1972 SetHelp(
Count() ?
tr(
"Button$Record") : NULL,
tr(
"Button$Now"),
tr(
"Button$Next"),
tr(
"Button$Switch"));
1977 else if (HadSubMenu &&
Update())
1996 const char *s = Command->Text();
1997 if (Command->SubItems())
2011 const char *p = strchr(s,
':');
2018 if (l > 1 && t[l - 1] ==
'?') {
2046 const char *cmd = *cmdbuf ? *cmdbuf : *
command;
2047 dsyslog(
"executing command '%s'", cmd);
2049 if (p.
Open(cmd,
"r")) {
2052 while ((c = fgetc(p)) != EOF) {
2054 if (
char *NewBuffer = (
char *)realloc(
result, l + 21))
2057 esyslog(
"ERROR: out of memory");
2068 esyslog(
"ERROR: can't open pipe for command '%s'", cmd);
2207 const char *p = strchr(s,
'\n');
2208 int l = p ? p - s : strlen(s);
2211 item->
SetText(strndup(s, l),
false);
2256 else if (state ==
osBack) {
2283 if (CamSlot->HasUserIO())
2384 if (*
Text() ==
'\t')
2404 DisplayMenu->
SetItem(
Text(), Index, Current, Selectable);
2452 Add(
new cOsdItem((dirSize > 9999) ? cString::sprintf(
"%s:\t%.2f GB%s",
tr(
"Size"), dirSize / 1024.0, *bitRate) : cString::sprintf(
"%s:\t%d MB%s",
tr(
"Size"), dirSize, *bitRate),
osUnknown,
false));
2461 isResume = (ResumeFile.Read() != -1);
2471 SetHelp(
tr(
"Button$Folder"),
tr(
"Button$Cut"),
tr(
"Button$Copy"),
tr(
"Button$Rename/Move"));
2487 memmove(
name, p, strlen(p) + 1);
2571 :
cOsdMenu(Base ? Base :
tr(
"Recordings"), 9, 6, 6)
2574 base = Base ? strdup(Base) : NULL;
2597 int NewHelpKeys = 0;
2608 switch (NewHelpKeys) {
2610 case 1:
SetHelp(
tr(
"Button$Open"));
break;
2626 CurrentRecording = ri->Recording()->FileName();
2638 if (p->Name() && strcmp(p->Name(), Item->
Name()) == 0) {
2644 if (*Item->
Text() && !LastDir) {
2652 if (LastItem || LastDir) {
2653 if (CurrentRecording && strcmp(CurrentRecording, recording->FileName()) == 0)
2679 const char *t = ri->
Name();
2757 if (!recording || recording->
Delete()) {
2860 virtual void Store(
void);
2893 virtual void Set(
void);
2978 bool ModifiedAppearance =
false;
2987 ModifiedAppearance =
true;
2996 ModifiedAppearance =
true;
2998 ModifiedAppearance =
true;
3003 ModifiedAppearance =
true;
3005 ModifiedAppearance =
true;
3007 ModifiedAppearance =
true;
3016 if (ModifiedAppearance) {
3112 for (k = 0; k < oldnumLanguages; k++) {
3116 if (k >= oldnumLanguages) {
3172 SetHelp(NULL,
tr(
"Button$Audio"),
tr(
"Button$Subtitles"), NULL);
3209 int oldPrimaryDVB =
::Setup.PrimaryDVB;
3210 int oldVideoDisplayFormat =
::Setup.VideoDisplayFormat;
3211 bool oldVideoFormat =
::Setup.VideoFormat;
3213 bool oldDisplaySubtitles =
::Setup.DisplaySubtitles;
3235 for (k = 0; k < oldnumAudioLanguages; k++) {
3239 if (k >= oldnumAudioLanguages) {
3253 for (k = 0; k < oldnumSubtitleLanguages; k++) {
3257 if (k >= oldnumSubtitleLanguages) {
3272 if (::
Setup.PrimaryDVB != oldPrimaryDVB)
3274 if (::
Setup.VideoDisplayFormat != oldVideoDisplayFormat)
3276 if (::
Setup.VideoFormat != oldVideoFormat)
3278 if (::
Setup.DisplaySubtitles != oldDisplaySubtitles)
3318 int NumSatDevices = 0;
3323 if (NumSatDevices > 1) {
3339 bool DeviceBondingsChanged =
false;
3349 else if (DeviceBondingsChanged)
3378 case msReset: CamName =
tr(
"CAM reset");
break;
3379 case msPresent: CamName =
tr(
"CAM present");
break;
3380 case msReady: CamName =
tr(
"CAM ready");
break;
3381 default: CamName =
"-";
break;
3385 if (strcmp(buffer,
Text()) != 0) {
3418 time_t t0 = time(NULL);
3513 virtual void Store(
void);
3591 for (
int i = 0; ; i++) {
3634 virtual void Set(
void);
3652 snprintf(buffer,
sizeof(buffer),
"%s - VDR %s",
tr(
"Setup"),
VDRVERSION);
3722 #define STOP_RECORDING trNOOP(" Stop recording ")
3789 for (
int i = 0; ; i++) {
3813 bool result =
false;
3816 if (Force || NewReplaying !=
replaying) {
3864 const char *s = NULL;
3951 default:
switch (Key) {
3953 case kRed:
if (!HadSubMenu)
3956 case kGreen:
if (!HadSubMenu) {
3961 case kYellow:
if (!HadSubMenu)
3964 case kBlue:
if (!HadSubMenu)
4018 int indexSubtitle = 0;
4022 case 2:
if (p->
type == 0x05)
4159 if (n <= ch->Number() && ch->
Number() < n + m) {
4194 int SaveGroup =
group;
4273 if ((Key & (k_Repeat |
k_Release)) == 0) {
4300 #define VOLUMETIMEOUT 1000 //ms
4301 #define MUTETIMEOUT 5000 //ms
4367 #define TRACKTIMEOUT 5000 //ms
4382 if (TrackId && TrackId->
id) {
4385 if (i == CurrentAudioTrack)
4434 int oldTrack =
track;
4451 static int ac[] = { 1, 0, 2 };
4478 if (
track != oldTrack) {
4503 if (TrackId && TrackId->
id) {
4506 if (i == CurrentSubtitleTrack)
4552 int oldTrack =
track;
4579 if (
track != oldTrack) {
4615 fileName = strdup(Recording.FileName());
4640 Recording.WriteInfo();
4646 char *Directory = strdup(
fileName);
4648 if (
char *p = strrchr(Directory,
'/')) {
4649 while (p > Directory && *--p !=
'/')
4653 dsyslog(
"setting %s to be sorted by time", Directory);
4678 #define INSTANT_REC_EPG_LOOKAHEAD 300 // seconds to look into the EPG data for an instant recording
4694 dsyslog(
"got EPG info after %d seconds", seconds);
4701 dsyslog(
"waiting for EPG info...");
4704 dsyslog(
"no EPG info available");
4715 if (ExecuteUserCommand)
4739 static time_t LastNoDiskSpaceMessage = 0;
4748 isyslog(
"not enough disk space to start recording%s%s", Timer ?
" timer " :
"", Timer ? *Timer->
ToDescr() :
"");
4750 LastNoDiskSpaceMessage = time(NULL);
4754 LastNoDiskSpaceMessage = 0;
4769 if (!Timer || Timer->
Matches()) {
4778 else if (!Timer || !Timer->
Pending()) {
4779 isyslog(
"no free DVB device to record channel %d!", ch);
4784 esyslog(
"ERROR: channel %d not defined!", ch);
4794 if (
id && strcmp(
id, InstantId) == 0) {
4812 if (
Start(NULL,
true)) {
4829 if (LastInstantId && LastInstantId ==
RecordControls[i]->InstantId())
4830 LastInstantId = NULL;
4874 isyslog(
"stopping recording due to modification of channel %d", Channel->
Number());
4903 int NewState =
state;
4904 bool Result = State != NewState;
4911 #define REPLAYCONTROLSKIPLIMIT 9 // s
4912 #define REPLAYCONTROLSKIPSECONDS 90 // s
4913 #define REPLAYCONTROLSKIPTIMEOUT 5000 // ms
4969 if (recording->
Delete()) {
5049 bool NormalPlay = (Play && Speed == -1);
5072 if (
GetIndex(Current, Total) && Total > 0) {
5090 Index = Current - Index;
5113 strcpy(buf,
tr(
"Jump: "));
5114 int len = strlen(buf);
5123 sprintf(buf + len,
"%c%c:%c%c", ch10, ch1, cm10, cm1);
5129 #define STAY_SECONDS_OFF_END 10
5201 if (
GetIndex(Current, Total,
true)) {
5210 Goto(Current,
true);
5225 Goto(m->Position(),
true);
5232 Goto(Forward ? Total : 0,
true);
5253 Goto(m->Position(),
true);
5287 if ((m->
Index() & 0x01) != 0)
5344 bool DoShowMode =
true;
int Find(const char *s) const
cDisplaySubtitleTracks(void)
void ShowTimed(int Seconds=0)
const cEvent * GetPresentEvent(void) const
static cString ToString(int Code)
bool Replaying(void) const
Returns true if we are currently replaying.
int DeviceNumber(void) const
Returns the number of this device (0 ... numDevices).
virtual void SetTrack(int Index, const char *const *Tracks)=0
< This class implements the track display.
cOsdItem * stopReplayItem
cString NewVideoFileName(const char *FileName, const char *NewDirName)
time_t startTime(void) const
eOSState ProcessKey(eKeys Key)
virtual int Compare(const cListObject &ListObject) const
Must return 0 if this object is equal to ListObject, a positive value if it is "greater", and a negative value if it is "smaller".
cList< cNestedItem > * commands
virtual cSkinDisplayVolume * DisplayVolume(void)=0
Creates and returns a new object for displaying the current volume.
const char * Text(void) const
virtual eOSState ProcessKey(eKeys Key)
void TimeSearchDisplay(void)
bool Confirm(const char *s, int Seconds=10, bool WaitForTimeout=false)
static void ResetVersions(void)
int GetPrevGroup(int Idx)
int I18nCurrentLanguage(void)
Returns the index of the current language.
void SetRecording(bool Recording)
void DisplayChannel(void)
bool Load(void)
Loads the current list of recordings and returns true if there is anything in it (for compatibility w...
cMark * GetPrev(int Position)
virtual void GetData(cChannel *Channel)=0
Copies all source specific parameters to the given Channel.
void SetRecordingsSortMode(const char *Directory, eRecordingsSortMode SortMode)
const cRecordingInfo * Info(void) const
void ResetResume(const char *ResumeFileName=NULL)
bool Load(const char *SkinName)
cRecordControl(cDevice *Device, cTimer *Timer=NULL, bool Pause=false)
virtual const cRecording * GetRecording(void)
Returns the cRecording that is currently being replayed, or NULL if this player is not playing a cRec...
cOsdItem * stopRecordingItem
void Add(cListObject *Object, cListObject *After=NULL)
static cString ToText(const cChannel *Channel)
double FramesPerSecond(void)
cSourceParam * Get(char Source) const
void DelByName(const char *FileName, bool RemoveRecording=true)
virtual void SetVolume(int Current, int Total, bool Mute)=0
< This class implements the volume/mute display.
static void Shutdown(void)
static void InvokeCommand(const char *State, const char *RecordingFileName, const char *SourceFileName=NULL)
double FramesPerSecond(void) const
virtual const char * Version(void)=0
char language[MAXLANGCODE2]
const char * Title(char Delimiter= ' ', bool NewIndicator=false, int Level=-1) const
#define RUC_BEFORERECORDING
cNestedItemList TimerCommands
static const char * SystemCharacterTable(void)
bool repTimer(void) const
#define TIMERMACRO_EPISODE
static cString sprintf(const char *fmt,...) __attribute__((format(printf
const char * DefaultFontSml
const char * VideoDirectory
bool DayMatches(time_t t) const
virtual cOsdObject * MainMenuAction(void)
static cDisplayVolume * Create(void)
cMenuMain(eOSState State=osUnknown, bool OpenSubMenus=false)
cString PrintFirstDay(void) const
cTimer * GetMatch(time_t t)
const cEvent * Event(void) const
static void SetupChanged(void)
virtual void SetVideoDisplayFormat(eVideoDisplayFormat VideoDisplayFormat)
Sets the video display format to the given one (only useful if this device has an MPEG decoder)...
static void ChannelDataModified(cChannel *Channel)
bool Parse(const char *s)
bool Matches(time_t t=0, bool Directly=false, int Margin=0) const
static cDevice * GetDevice(int Index)
Gets the device with the given Index.
cOsdItem * Get(int Index) const
const char * ShortName(bool OrName=false) const
static cControl * Control(bool Hidden=false)
Returns the current replay control (if any) in case it is currently visible.
static void Process(time_t t)
bool AttachReceiver(cReceiver *Receiver)
Attaches the given receiver to this device.
char FontSml[MAXFONTNAME]
int AlwaysSortFoldersFirst
bool SetAvailableTrack(eTrackType Type, int Index, uint16_t Id, const char *Language=NULL, const char *Description=NULL)
Sets the track of the given Type and Index to the given values.
int EPGLanguages[I18N_MAX_LANGUAGES+1]
bool GroupSep(void) const
const cComponents * Components(void) const
virtual eOSState ProcessKey(eKeys Key)
eTrackType types[ttMaxTrackTypes]
cTimerEntry(cMenuTimerItem *item)
tComponent * Component(int Index) const
void SetSubItems(bool On)
cSkinDisplayReplay * displayReplay
eOSState ProcessKey(eKeys Key)
static void Process(eKeys Key)
static cDisplayChannel * currentDisplayChannel
static int NumDevices(void)
Returns the total number of devices.
virtual void SetMode(bool Play, bool Forward, int Speed)=0
Sets the current replay mode, which can be used to display some indicator, showing the user whether w...
void SetPending(bool Pending)
eTrackType GetCurrentSubtitleTrack(void) const
void Exit(int ExitCode)
Set VDR exit code and initiate end of VDR main loop.
time_t StartTime(void) const
int weekdays
bitmask, lowest bits: SSFTWTM (the 'M' is the LSB)
time_t StartTime(void) const
void SetPosition(int Position)
void SetText(const char *Text)
static bool StateChanged(int &State)
virtual void SetVideoFormat(bool VideoFormat16_9)
Sets the output video format to either 16:9 or 4:3 (only useful if this device has an MPEG decoder)...
cString ChannelString(const cChannel *Channel, int Number)
int GetThemeIndex(const char *Description)
virtual void SetJump(const char *Jump)=0
Sets the prompt that allows the user to enter a jump point.
const char * Convert(const char *From, char *To=NULL, size_t ToLength=0)
Converts the given Text from FromCode to ToCode (as set in the constructor).
void Add(cTimer *Timer, cTimer *After=NULL)
virtual eOSState ProcessKey(eKeys Key)
void SetNeedsFastResponse(bool NeedsFastResponse)
void I18nSetLocale(const char *Locale)
Sets the current locale to Locale.
eModuleStatus ModuleStatus(void)
Returns the status of the CAM in this slot.
static const cSchedules * Schedules(cSchedulesLock &SchedulesLock)
Caller must provide a cSchedulesLock which has to survive the entire time the returned cSchedules is ...
virtual void SetRecording(const cRecording *Recording)
Sets the recording that is currently being played.
cNestedItemList RecordingCommands
cString IndexToHMSF(int Index, bool WithFrame, double FramesPerSecond)
const cChannel * Channel(void) const
bool SetCurrentAudioTrack(eTrackType Type)
Sets the current audio track to the given Type.
const cTimer * Timer(void) const
static void SetRecording(const char *FileName)
static int CurrentVolume(void)
void EnsureSubtitleTrack(void)
Makes sure one of the preferred language subtitle tracks is selected.
virtual int Compare(const cListObject &ListObject) const
Must return 0 if this object is equal to ListObject, a positive value if it is "greater", and a negative value if it is "smaller".
virtual const char * Description(void)=0
void SetEventFromSchedule(const cSchedules *Schedules=NULL)
cDisplayChannel(int Number, bool Switched)
bool Transferring(void) const
Returns true if we are currently in Transfer Mode.
virtual void SetMarks(const cMarks *Marks)
Sets the editing marks to Marks, which shall be used to display the progress bar through a cProgressB...
const char * Text(void) const
bool Recording(void) const
cDevice * Device(void)
Returns the device this CAM slot is currently assigned to.
cTimer * GetTimer(cTimer *Timer)
cTimerEntry(const cTimer *timer, time_t start)
cRecording * GetByName(const char *FileName)
static int CurrentChannel(void)
Returns the number of the current channel on the primary device.
const char * Name(void) const
bool Selectable(void) const
const char * I18nLocale(int Language)
Returns the locale code of the given Language (which is an index as returned by I18nCurrentLanguage()...
static cPlugin * CallFirstService(const char *Id, void *Data=NULL)
cMark * GetNext(int Position)
T * Next(const T *object) const
static cDisplayTracks * currentDisplayTracks
void GetRecordingsSortMode(const char *Directory)
cMenuCommands(const char *Title, cList< cNestedItem > *Commands, const char *Parameters=NULL)
virtual void Flush(void)
Actually draws the OSD display to the output device.
static bool BondDevices(const char *Bondings)
Bonds the devices as defined in the given Bondings string.
char * descriptions[ttMaxTrackTypes+1]
virtual cOsdItem * GetOsdItem(void)=0
Returns all the OSD items necessary for editing the source specific parameters of the channel that wa...
bool Modified(int &State)
Returns true if any of the timers have been modified, which is detected by State being different than...
void DecBeingEdited(void)
virtual void Insert(T Data, int Before=0)
static bool Start(const char *FileName, const char *TargetFileName=NULL, bool Overwrite=true)
int SubtitleFgTransparency
const char *const * Descriptions(void)
virtual ~cDisplayVolume()
bool HasUserIO(void)
Returns true if there is a pending user interaction, which shall be retrieved via GetMenu() or GetEnq...
cListObject * Next(void) const
virtual cOsdObject * GetInfo(void)
Returns an OSD object that displays information about the currently played programme.
cCiMenu * GetMenu(void)
Gets a pending menu, or NULL if there is no menu.
cSkinDisplayTracks * displayTracks
cOsdItem * cancelFileTransferItem
bool FromString(const char *s)
bool SwitchChannel(const cChannel *Channel, bool LiveView)
Switches the device to the given Channel, initiating transfer mode if necessary.
virtual cSkinDisplayReplay * DisplayReplay(bool ModeOnly)=0
Creates and returns a new object for displaying replay progress.
void IncBeingEdited(void)
char FontOsd[MAXFONTNAME]
const char * Description(void)
Returns a user visible, single line description of this theme.
int GetNextNormal(int Idx)
int LengthInSeconds(void) const
Returns the length (in seconds) of this recording, or -1 in case of error.
tChannelID ChannelID(void) const
static int GetMDay(time_t t)
bool HasFlags(uint Flags) const
static void SleepMs(int TimeoutMs)
Creates a cCondWait object and uses it to sleep for TimeoutMs milliseconds, immediately giving up the...
cOsdItem * cancelEditingItem
void SetDiskStatus(char DiskStatus)
void SetText(const char *Text, bool Copy=true)
cSkinDisplayVolume * displayVolume
void SetSelectable(bool Selectable)
int GetPrevNormal(int Idx)
const cList< cEvent > * Events(void) const
bool IsAttached(void)
Returns true if this receiver is (still) attached to a device.
static void MsgSetAudioChannel(int AudioChannel)
bool Load(const char *FileName, bool OnlyDescriptions=false)
Loads the theme data from the given file.
void ClrAvailableTracks(bool DescriptionsOnly=false, bool IdsOnly=false)
Clears the list of currently available tracks.
static void UpdateOsdSize(bool Force=false)
Inquires the actual size of the video display and adjusts the OSD and font sizes accordingly.
const cEvent * GetEventAround(time_t Time) const
cSourceParams SourceParams
static const cCursesFont Font
bool Open(const char *Command, const char *Mode)
#define IS_AUDIO_TRACK(t)
int SubtitleLanguages[I18N_MAX_LANGUAGES+1]
virtual cMenuSetupPage * SetupMenu(void)
virtual ~cDisplayChannel()
bool Delete(void)
Changes the file name so that it will no longer be visible in the "Recordings" menu Returns false in ...
cList< cNestedItem > * SubItems(void)
bool Put(uint64_t Code, bool Repeat=false, bool Release=false)
tChannelID GetChannelID(void) const
cShutdownHandler ShutdownHandler
const char * InstantId(void)
cSkinDisplayTracks * displayTracks
static int IsOpen(void)
Returns true if there is currently a level 0 OSD open.
virtual ~cReplayControl()
void SetModified(bool ByUser=false)
int GetNextGroup(int Idx)
void IncBeingEdited(void)
static void Stop(const char *InstantId)
bool HasRecordingsSortMode(const char *Directory)
const char * Provider(void) const
static cDisplaySubtitleTracks * Create(void)
virtual ~cRecordControl()
time_t day
midnight of the day this timer shall hit, or of the first day it shall hit in case of a repeating tim...
static time_t IncDay(time_t t, int Days)
#define RUC_AFTERRECORDING
cChannel * GetByChannelID(tChannelID ChannelID, bool TryWithoutRid=false, bool TryWithoutPolarization=false)
void Stop(bool ExecuteUserCommand=true)
bool GetIndex(int &Current, int &Total, bool SnapToIFrame=false)
static void Launch(cControl *Control)
void MarkJump(bool Forward)
static const char * LastReplayed(void)
eKeys Message(eMessageType Type, const char *s, int Seconds=0)
Displays the given message, either through a currently visible display object that is capable of doin...
static void MsgOsdTextItem(const char *Text, bool Scroll=false)
virtual eOSState ProcessKey(eKeys Key)
bool HasTimer(void) const
bool ShowProgress(bool Initial)
const char * Title(void) const
bool Reset(void)
Resets the CAM in this slot.
static cDisplaySubtitleTracks * currentDisplayTracks
eOSState ProcessKey(eKeys Key)
bool GetReplayMode(bool &Play, bool &Forward, int &Speed)
static const char * GetInstantId(const char *LastInstantId)
const char * DefaultFontFix
int CardIndex(void) const
Returns the card index of this device (0 ... MAXDEVICES - 1).
static bool HasPlugins(void)
static void TriggerLastActivity(void)
Simulates user activity, for instance to keep the current menu open even if no remote control key has...
static void MsgSetAudioTrack(int Index, const char *const *Tracks)
static void MsgOsdProgramme(time_t PresentTime, const char *PresentTitle, const char *PresentSubtitle, time_t FollowingTime, const char *FollowingTitle, const char *FollowingSubtitle)
const char * Description(void) const
const char * Name(int Index)
static cRecordControl * RecordControls[]
virtual void SetProgress(int Current, int Total)=0
This function will be called whenever the position in or the total length of the recording has change...
const cSchedule * GetSchedule(tChannelID ChannelID) const
void TimeSearchProcess(eKeys Key)
static bool Active(const char *FileName=NULL)
Returns true if the cutter is currently active.
cString ToDescr(void) const
cCiEnquiry * GetEnquiry(void)
Gets a pending enquiry, or NULL if there is no enquiry.
static void ClearLastReplayed(const char *FileName)
int GetNumSequences(void)
Returns the actual number of sequences to be cut from the recording.
static void MsgOsdChannel(const char *Text)
static void MsgSetSubtitleTrack(int Index, const char *const *Tracks)
void DecBeingEdited(void)
const cEvent * lastFollowing
int VideoDiskSpace(int *FreeMB, int *UsedMB)
bool HasUniqueChannelID(cChannel *NewChannel, cChannel *OldChannel=NULL)
virtual eOSState ProcessKey(eKeys Key)
cListObject * Prev(void) const
virtual const char * MainMenuEntry(void)
void Del(cListObject *Object, bool DeleteObject=true)
cString ToString(void) const
static void Process(eKeys Key)
char FontFix[MAXFONTNAME]
int ShowChannelNamesWithSource
static void Process(eKeys Key)
static void MsgOsdClear(void)
time_t StopTime(void) const
cChannel * GetByNumber(int Number, int SkipGap=0)
void EnsureAudioTrack(bool Force=false)
Makes sure an audio track is selected that is actually available.
int AudioLanguages[I18N_MAX_LANGUAGES+1]
static cOsdObject * pluginOsdObject
void Reply(const char *s)
cMark * Get(int Position)
static cDevice * PrimaryDevice(void)
Returns the primary device.
static bool Start(cRecording *Recording, const char *NewName, bool CopyOnly=false)
void SetFlags(uint Flags)
virtual void SetTotal(const char *Total)=0
Sets the total length of the recording, as a user readable string if the form "h:mm:ss".
static bool GetAvailableFontNames(cStringList *FontNames, bool Monospaced=false)
Queries the font configuration for a list of available font names, which is returned in FontNames...
#define MAXEPGBUGFIXLEVEL
const cStringList * I18nLanguages(void)
Returns the list of available languages.
bool HasMMI(void)
Returns 'true' if the CAM in this slot has an active MMI.
cChannel * NextAvailableChannel(cChannel *Channel, int Direction)
void SetDeferred(int Seconds)
virtual ~cDisplayTracks()
static cDisplayTracks * Create(void)
void StopReplay(void)
Stops the current replay session (if any).
const tTrackId * GetTrack(eTrackType Type)
Returns a pointer to the given track id, or NULL if Type is not less than ttMaxTrackTypes.
const char * GetCamName(void)
Returns the name of the CAM in this slot, or NULL if there is no ready CAM in this slot...
cSkinDisplayChannel * displayChannel
const char * File(void) const
int GetAudioChannel(void)
Gets the current audio channel, which is stereo (0), mono left (1) or mono right (2).
bool IsSingleEvent(void) const
int I18nNumLanguagesWithLocale(void)
Returns the number of entries in the list returned by I18nLanguages() that actually have a locale...
virtual void Move(int From, int To)
cRecordings Recordings
Any access to Recordings that loops through the list of recordings needs to hold a thread lock on thi...
bool ConfirmRestart(bool Ask)
Check for background activity that blocks restart.
static cReplayControl * currentReplayControl
static void SetCurrentChannel(const cChannel *Channel)
Sets the number of the current channel on the primary device, without actually switching to it...
cString GetTimeString(void) const
void IncRecordingsSortMode(const char *Directory)
int NumComponents(void) const
const char * Description(void) const
const char * Name(void) const
static void ChangeState(void)
void AssertFreeDiskSpace(int Priority, bool Force)
The special Priority value -1 means that we shall get rid of any deleted recordings faster than norma...
virtual void SetAudioChannel(int AudioChannel)=0
Sets the audio channel indicator.
eTrackType types[ttMaxTrackTypes]
static cRecordControl * GetRecordControl(const char *FileName)
static cPlugin * GetPlugin(int Index)
const char * Title(void) const
virtual ~cDisplaySubtitleTracks()
const char * Description(void) const
void ClearSortNames(void)
int SecondsToFrames(int Seconds, double FramesPerSecond)
bool StateChanged(int &State)
void SetKeepTracks(bool KeepTracks)
Controls whether the current audio and subtitle track settings shall be kept as they currently are...
const cComponents * Components(void) const
char language[MAXLANGCODE2]
void I18nSetLanguage(int Language)
Sets the current language index to Language.
bool Load(const char *RecordingFileName, double FramesPerSecond=DEFAULTFRAMESPERSECOND, bool IsPesRecording=false)
bool SwitchTo(int Number)
time_t FirstDay(void) const
static cOsdObject * PluginOsdObject(void)
virtual bool ProvidesSource(int Source) const
Returns true if this device can provide the given source.
virtual void SetCurrent(const char *Current)=0
Sets the current position within the recording, as a user readable string if the form "h:mm:ss...
char NameInstantRecord[NAME_MAX+1]
bool EnterMenu(void)
Requests the CAM in this slot to start its menu.
virtual void SetEvents(const cEvent *Present, const cEvent *Following)=0
Sets the Present and Following EPG events.
void SetAudioChannel(int AudioChannel)
Sets the audio channel to stereo (0), mono left (1) or mono right (2).
cReplayControl(bool PauseLive=false)
void Goto(int Index, bool Still=false)
int SkipFrames(int Frames)
#define IS_DOLBY_TRACK(t)
char * ExchangeChars(char *s, bool ToFileSystem)
const char * FileName(int Index)
const char * ShortText(void) const
char OSDTheme[MaxThemeName]
bool SetCurrentSubtitleTrack(eTrackType Type, bool Manual=false)
Sets the current subtitle track to the given Type.
const char * DefaultFontOsd
#define MAXVIDEOFILESIZETS
char OSDSkin[MaxSkinName]
static bool PauseLiveVideo(void)
cSkin * Current(void)
Returns a pointer to the current skin.
const char * FileName(void) const
static void ForceCheck(void)
To avoid unnecessary load, the video disk usage is only actually checked every DISKSPACECHEK seconds...
void Del(cTimer *Timer, bool DeleteObject=true)
void SkipSeconds(int Seconds)
bool Update(bool Force=false)
eTrackType GetCurrentAudioTrack(void) const
const cEvent * lastPresent
virtual cSkinDisplayTracks * DisplayTracks(const char *Title, int NumTracks, const char *const *Tracks)=0
Creates and returns a new object for displaying the available tracks.
T * Prev(const T *object) const
bool SetCurrent(const char *Name=NULL)
Sets the current skin to the one indicated by name.
static void Shutdown(void)
virtual cSkinDisplayChannel * DisplayChannel(bool WithInfo)=0
Creates and returns a new object for displaying the current channel.
void AddByName(const char *FileName, bool TriggerUpdate=true)
char OSDLanguage[I18N_MAX_LOCALE_LEN]
bool IsPesRecording(void) const
void RequestEmergencyExit(void)
Requests an emergency exit of the VDR main loop.
static cDisplayVolume * currentDisplayVolume
int SubtitleBgTransparency
int SlotNumber(void)
Returns the number of this CAM slot within the whole system.
The cDevice class is the base from which actual devices can be derived.
static void MsgRecording(const cDevice *Device, const char *Name, const char *FileName, bool On)
static const char * NowReplaying(void)
char * descriptions[ttMaxTrackTypes+1]
virtual void SetData(cChannel *Channel)=0
Sets all source specific parameters to those of the given Channel.
void MarkMove(bool Forward)
static void MsgReplaying(const cControl *Control, const char *Name, const char *FileName, bool On)
static cString PrintDay(time_t Day, int WeekDays, bool SingleByteChars)
virtual void SetChannel(const cChannel *Channel, int Number)=0
< This class is used to display the current channel, together with the present and following EPG even...
const cEvent * GetFollowingEvent(void) const
static bool Start(cTimer *Timer=NULL, bool Pause=false)