summaryrefslogtreecommitdiff
path: root/pages/pageelems.ecpp
diff options
context:
space:
mode:
authorChristian Wieninger <cwieninger (at) gmx (dot) de>2007-05-03 18:17:16 +0000
committerChristian Wieninger <cwieninger (at) gmx (dot) de>2007-05-03 18:17:16 +0000
commit3a0ab012c018c1d5093c8cdc89537a9d4467afb0 (patch)
treed8b999b85e95f725f2dfba00fdf2eae91e9b50d8 /pages/pageelems.ecpp
parent69d1982a650657a4cd2d17b818c3d7bdc3e969e4 (diff)
downloadvdr-plugin-live-3a0ab012c018c1d5093c8cdc89537a9d4467afb0.tar.gz
vdr-plugin-live-3a0ab012c018c1d5093c8cdc89537a9d4467afb0.tar.bz2
- EPG pages now display record.png or record_timer.png depending on an existing timer
- If record_timer.png is displayed one can now edit the timer for an event
Diffstat (limited to 'pages/pageelems.ecpp')
-rw-r--r--pages/pageelems.ecpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/pages/pageelems.ecpp b/pages/pageelems.ecpp
index 74af3dd..7acf72a 100644
--- a/pages/pageelems.ecpp
+++ b/pages/pageelems.ecpp
@@ -4,6 +4,7 @@
#include <vdr/epg.h>
#include "tools.h"
#include "i18n.h"
+#include "timers.h"
using namespace std;
using namespace vdrlive;
@@ -88,7 +89,16 @@ using namespace vdrlive;
tChannelID channelid;
tEventID eventid;
</%args>
- <a href="edit_timer.html?channelid=<$ channelid $>&eventid=<$ eventid $>"><img src="record.png" alt="" <& tooltip.hint text=(tr("Record this")) &> /></a>
+<%cpp> const cTimer* timer = LiveTimerManager().GetTimer(eventid, channelid);
+ if (timer) {
+</%cpp>
+ <a href="edit_timer.html?timerid=<$ LiveTimerManager().GetTimers().GetTimerId(*timer) $>">
+ <img src="record_timer.png" alt="" <& tooltip.hint text=(tr("Edit this")) &> />
+<%cpp> } else { </%cpp>
+ <a href="edit_timer.html?channelid=<$ channelid $>&eventid=<$ eventid $>">
+ <img src="record.png" alt="" <& tooltip.hint text=(tr("Record this")) &> />
+<%cpp> } </%cpp>
+ </a>
</%def>
<# ---------------------------------------------------------------------- #>