summaryrefslogtreecommitdiff
path: root/pages/whats_on.ecpp
diff options
context:
space:
mode:
Diffstat (limited to 'pages/whats_on.ecpp')
-rw-r--r--pages/whats_on.ecpp38
1 files changed, 18 insertions, 20 deletions
diff --git a/pages/whats_on.ecpp b/pages/whats_on.ecpp
index 8f052ce..d149e55 100644
--- a/pages/whats_on.ecpp
+++ b/pages/whats_on.ecpp
@@ -79,7 +79,6 @@ if (type == "now") {
<head>
<title>VDR-Live - <$ head $></title>
<& pageelems.stylesheets &>
- <& tooltip.javascript var=("domTT_styleClass") value=("domTTepg") &>
<& pageelems.ajax_js &>
<script type="text/javascript"><!--
function showtime(selection)
@@ -109,7 +108,7 @@ if (type == "now") {
ReadLock channelsLock( Channels );
if (channelsLock) {
- int evntNr = 0;
+ // int evntNr = 0;
for (cChannel *Channel = Channels.First(); Channel && Channel->Number() <= LiveSetup().GetLastChannel(); Channel = Channels.Next(Channel)) {
if (Channel->GroupSep()) {
continue;
@@ -129,13 +128,23 @@ if (type == "now") {
continue;
}
- string evntId("eventId_");
- evntId += lexical_cast<std::string, int>(++evntNr);
- EpgEventPtr epgEvent(new EpgEvent(evntId, Event, Channel->Name()));
- epgEvents.push_back(epgEvent);
tChannelID channel_id(Channel->GetChannelID());
tEventID event = Event->EventID();
+
+ // string evntId("event_");
+ //
+ // string schanid(channel_id.ToString());
+ // replace(schanid.begin(), schanid.end(), '.', 'p');
+ // replace(schanid.begin(), schanid.end(), '-', 'm');
+ // evntId += schanid;
+ // evntId += '_';
+ // evntId += lexical_cast<std::string>(event);
+ // // evntId += lexical_cast<std::string, int>(++evntNr);
+ // EpgEventPtr epgEvent(new EpgEvent(evntId, Event, Channel->Name()));
+ // // epgEvents.push_back(epgEvent);
+ EpgInfoPtr epgEvent = EpgEvents::CreateEpgInfo(Channel, Event);
+
bool truncated = false;
string truncDescription = StringWordTruncate(epgEvent->LongDescr(), maximumTooltipHintLength, truncated);
string longDescription = StringEscapeAndBreak(StringWordTruncate(epgEvent->LongDescr(), maximumDescriptionLength))
@@ -168,7 +177,7 @@ if (type == "now") {
<div class="short withmargin"><$ (epgEvent->ShortDescr()) $></div>
<div class="description withmargin"><$ truncDescription $></div>
% if (truncated) {
- <div class="more withmargin"<& tooltip.hint text=(longDescription) &><& tooltip.display domId=(epgEvent->Id()) &>><$ tr("more") $> ...</div>
+ <div class="more withmargin"><a <& tooltip.hint text=(longDescription) &><& tooltip.display domId=(epgEvent->Id()) &>><$ tr("more") $> ...</a></div>
% }
</div>
</div>
@@ -193,11 +202,11 @@ if (type == "now") {
</div>
</td>
<td class="topaligned <? lastCurrentChanel ? "bottomrow"?>">
- <div class="more withmargin"
+ <div class="more withmargin"><a
% if (!longDescription.empty()) {
<& tooltip.hint text=(longDescription) &><& tooltip.display domId=(epgEvent->Id()) &>
% }
- ><span class="title"><$ (epgEvent->Title()) $></span><br /><span class="short"><$ (epgEvent->ShortDescr()) $></span></div>
+ ><span class="title"><$ (epgEvent->Title()) $></span><br /><span class="short"><$ (epgEvent->ShortDescr()) $></span></a></div>
</td>
<td class="topaligned rightcol <? lastCurrentChanel ? "bottomrow"?>"><div class="station withmargin"><a href="schedule.html?channel=<$ Channel->Number() $>" <& tooltip.hint text=(tr("View the schedule of this channel")) &>><$ (epgEvent->Caption()) $></a></div></td>
</tr>
@@ -210,17 +219,6 @@ if (type == "now") {
</table>
% }
</div>
- <div class="epg_data" style="display: none;">
-<%cpp>
- // create hidden div for the tooltip hints.
- for (vector<EpgEventPtr>::iterator i = epgEvents.begin(); i != epgEvents.end(); ++i) {
- EpgEventPtr epg = *i;
-</%cpp>
- <& pageelems.epg_tt_box boxId=(epg->Id()) caption=(epg->Caption()) time=(epg->StartTime(tr("%I:%M %p")) + string(" - ") + epg->EndTime(tr("%I:%M %p"))) title=(epg->Title()) short_descr=(epg->ShortDescr()) long_descr=(epg->LongDescr()) elapsed=(epg->Elapsed()) &>
-<%cpp>
- }
-</%cpp>
- </div>
</body>
</html>
<%include>page_exit.eh</%include>