Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Add defaults for channels/bouquets and make better use of interface l…
…evels
  • Loading branch information
Glenn-1990 authored and perexg committed Oct 20, 2016
1 parent cf683f5 commit 1c6ac28
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
4 changes: 4 additions & 0 deletions src/bouquet.c
Expand Up @@ -94,6 +94,9 @@ bouquet_create(const char *uuid, htsmsg_t *conf,
bq->bq_active_services = idnode_set_create(1);
bq->bq_ext_url_period = 60;
bq->bq_mapencrypted = 1;
bq->bq_mapradio = 1;
bq->bq_maptoch = 1;
bq->bq_chtag = 1;

if (idnode_insert(&bq->bq_id, uuid, &bouquet_class, 0)) {
if (uuid)
Expand Down Expand Up @@ -978,6 +981,7 @@ const idclass_t bouquet_class = {
.id = "enabled",
.name = N_("Enabled"),
.desc = N_("Enable/disable the bouquet."),
.def.i = 1,
.off = offsetof(bouquet_t, bq_enabled),
.notify = bouquet_class_enabled_notify,
},
Expand Down
10 changes: 6 additions & 4 deletions src/channels.c
Expand Up @@ -376,6 +376,7 @@ const idclass_t channel_class = {
.id = "enabled",
.name = N_("Enabled"),
.desc = N_("Enable/disable the channel."),
.def.i = 1,
.off = offsetof(channel_t, ch_enabled),
},
{
Expand Down Expand Up @@ -439,6 +440,7 @@ const idclass_t channel_class = {
"turn this option off, only the OTA EPG grabber "
"will be used for this channel unless you've "
"specifically set a different EPG Source."),
.def.i = 1,
.off = offsetof(channel_t, ch_epgauto),
.opts = PO_ADVANCED,
},
Expand Down Expand Up @@ -489,7 +491,7 @@ const idclass_t channel_class = {
.doc = prop_doc_runningstate,
.off = offsetof(channel_t, ch_epg_running),
.list = channel_class_epg_running_list,
.opts = PO_ADVANCED | PO_DOC_NLIST,
.opts = PO_EXPERT | PO_DOC_NLIST,
},
{
.type = PT_STR,
Expand All @@ -501,7 +503,6 @@ const idclass_t channel_class = {
.set = channel_class_services_set,
.list = channel_class_services_enum,
.rend = channel_class_services_rend,
.opts = PO_ADVANCED
},
{
.type = PT_STR,
Expand Down Expand Up @@ -1419,6 +1420,7 @@ const idclass_t channel_tag_class = {
.id = "enabled",
.name = N_("Enabled"),
.desc = N_("Enable/disable the tag."),
.def.i = 1,
.off = offsetof(channel_tag_t, ct_enabled),
},
{
Expand Down Expand Up @@ -1452,7 +1454,7 @@ const idclass_t channel_tag_class = {
"no tags at all) set in "
"access configuration to use the tag."),
.off = offsetof(channel_tag_t, ct_private),
.opts = PO_ADVANCED
.opts = PO_EXPERT
},
{
.type = PT_STR,
Expand All @@ -1479,7 +1481,7 @@ const idclass_t channel_tag_class = {
.desc = N_("If set, presentation of the tag icon will not "
"superimpose the tag name on top of the icon."),
.off = offsetof(channel_tag_t, ct_titled_icon),
.opts = PO_ADVANCED
.opts = PO_EXPERT
},
{
.type = PT_STR,
Expand Down

0 comments on commit 1c6ac28

Please sign in to comment.