diff options
author | Jochen Dolze <vdr@dolze.de> | 2010-04-10 15:33:59 +0200 |
---|---|---|
committer | Jochen Dolze <vdr@dolze.de> | 2010-04-10 15:33:59 +0200 |
commit | b8fb66fe7f224892070debe4597b53c9beca6eb9 (patch) | |
tree | d727c1d92262606e629fdaa35c6330f86411f1f4 /plugin/menu.cpp | |
parent | 3b55b1b944442a26457fb92ba4147ca79e03b434 (diff) | |
download | vdr-plugin-markad-b8fb66fe7f224892070debe4597b53c9beca6eb9.tar.gz vdr-plugin-markad-b8fb66fe7f224892070debe4597b53c9beca6eb9.tar.bz2 |
Added more setup options, added MARK svdrp command
Diffstat (limited to 'plugin/menu.cpp')
-rw-r--r-- | plugin/menu.cpp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/plugin/menu.cpp b/plugin/menu.cpp index 75fa300..2d7c9a7 100644 --- a/plugin/menu.cpp +++ b/plugin/menu.cpp @@ -36,7 +36,7 @@ cOsdMarkAd::cOsdMarkAd(struct recs *Entry) } char *buf=NULL; - if (asprintf(&buf,"%s\t %s",entry->Name,status)!=-1) + if (asprintf(&buf,"%s\t %s",entry->Name ? entry->Name : entry->FileName,status)!=-1) { SetText(buf,true); free(buf); @@ -44,7 +44,7 @@ cOsdMarkAd::cOsdMarkAd(struct recs *Entry) else { // fallback - SetText(entry->Name,true); + SetText(entry->Name ? entry->Name : entry->FileName,true); } } @@ -93,14 +93,14 @@ bool cMenuMarkAd::write() do { status->GetNextActive(&Entry); - if ((Entry) && (Entry->Name)) + if (Entry) { if (!header) { header=true; Add(new cOsdItem(tr("Recording\t Status"),osUnknown,false)); } - Add(new cOsdMarkAd(Entry),first); + Add(new cOsdMarkAd(Entry)); first=false; } } @@ -154,10 +154,11 @@ eOSState cMenuMarkAd::ProcessKey(eKeys Key) if ((osd) && (osd->Selectable())) { struct recs *entry=osd->GetEntry(); - if ((entry) && (entry->Pid)) + if ((entry) && (entry->Pid) && (entry->Status!='T')) { dsyslog("sending TSTP to %i",entry->Pid); kill(entry->Pid,SIGTSTP); + entry->ChangedbyUser=true; SetHelp(NULL,tr("Continue")); } } @@ -172,6 +173,7 @@ eOSState cMenuMarkAd::ProcessKey(eKeys Key) { dsyslog("sending CONT to %i",entry->Pid); kill(entry->Pid,SIGCONT); + entry->ChangedbyUser=true; SetHelp(tr("Pause"),NULL); } } |