summaryrefslogtreecommitdiff
path: root/timers.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2008-02-16 15:04:49 +0100
committerKlaus Schmidinger <vdr@tvdr.de>2008-02-16 15:04:49 +0100
commit6140c49f146455f01897097e0393225382ec1885 (patch)
treed6a3312bfbc62bfa50a9729d19fa06188ed69931 /timers.c
parent6b35173789c2d97fc6b9dadb780a22316f82c7fb (diff)
downloadvdr-6140c49f146455f01897097e0393225382ec1885.tar.gz
vdr-6140c49f146455f01897097e0393225382ec1885.tar.bz2
Added cStatus::TimerChange()
Diffstat (limited to 'timers.c')
-rw-r--r--timers.c24
1 files changed, 22 insertions, 2 deletions
diff --git a/timers.c b/timers.c
index 1e9feec2..c76511e8 100644
--- a/timers.c
+++ b/timers.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: timers.c 1.72 2008/02/15 15:36:59 kls Exp $
+ * $Id: timers.c 1.73 2008/02/16 14:47:40 kls Exp $
*/
#include "timers.h"
@@ -15,6 +15,7 @@
#include "libsi/si.h"
#include "recording.h"
#include "remote.h"
+#include "status.h"
#define VFAT_MAX_FILENAME 40 // same as MAX_SUBTITLE_LENGTH in recording.c
@@ -136,7 +137,7 @@ int cTimer::Compare(const cListObject &ListObject) const
return r;
}
-cString cTimer::ToText(bool UseChannelID)
+cString cTimer::ToText(bool UseChannelID) const
{
strreplace(file, ':', '|');
cString buffer = cString::sprintf("%u:%s:%s:%04d:%04d:%d:%d:%s:%s\n", flags, UseChannelID ? *Channel()->GetChannelID().ToString() : *itoa(Channel()->Number()), *PrintDay(day, weekdays, true), start, stop, priority, lifetime, file, aux ? aux : "");
@@ -696,9 +697,28 @@ cTimer *cTimers::GetNextActiveTimer(void)
void cTimers::SetModified(void)
{
+ cStatus::MsgTimerChange(NULL, tcMod);
state++;
}
+void cTimers::Add(cTimer *Timer, cTimer *After)
+{
+ cConfig<cTimer>::Add(Timer, After);
+ cStatus::MsgTimerChange(Timer, tcAdd);
+}
+
+void cTimers::Ins(cTimer *Timer, cTimer *Before)
+{
+ cConfig<cTimer>::Ins(Timer, Before);
+ cStatus::MsgTimerChange(Timer, tcAdd);
+}
+
+void cTimers::Del(cTimer *Timer, bool DeleteObject)
+{
+ cStatus::MsgTimerChange(Timer, tcDel);
+ cConfig<cTimer>::Del(Timer, DeleteObject);
+}
+
bool cTimers::Modified(int &State)
{
bool Result = state != State;