HTSP: Send contentType for EPG entries

This commit is contained in:
Andreas Öman 2009-09-06 20:52:28 +00:00
parent e0c48dfd69
commit fa5b99b253
3 changed files with 5 additions and 0 deletions

View file

@ -445,6 +445,7 @@ epg_content_type_find_by_dvbcode(uint8_t dvbcode)
ect->ect_group = ecg;
snprintf(buf, sizeof(buf), "type%d", type);
ect->ect_name = strdup(buf);
ect->ect_dvbcode = dvbcode;
}
return ect;

View file

@ -38,6 +38,7 @@ typedef struct epg_content_type {
const char *ect_name;
struct event_list ect_events;
epg_content_group_t *ect_group;
uint8_t ect_dvbcode;
} epg_content_type_t;
/*

View file

@ -437,6 +437,9 @@ htsp_method_getEvent(htsp_connection_t *htsp, htsmsg_t *in)
if(e->e_desc != NULL)
htsmsg_add_str(out, "description", e->e_desc);
if(e->e_content_type != NULL)
htsmsg_add_u32(out, "contentType", e->e_content_type->ect_dvbcode);
n = RB_NEXT(e, e_channel_link);
if(n != NULL)
htsmsg_add_u32(out, "nextEventId", n->e_id);