From 8b44748176edc9c758e1840a01e7bd88b9c55bb8 Mon Sep 17 00:00:00 2001 From: Alhaziel <46535975+lozioangie@users.noreply.github.com> Date: Mon, 25 Mar 2019 21:53:05 +0100 Subject: [PATCH] Added a funtion to simplify menu construction --- plugin.video.alfa/channels/support.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/plugin.video.alfa/channels/support.py b/plugin.video.alfa/channels/support.py index b7b13809..9600ec65 100644 --- a/plugin.video.alfa/channels/support.py +++ b/plugin.video.alfa/channels/support.py @@ -245,3 +245,16 @@ def swzz_get_url(item): data = item.url return data + +def menu(itemlist, item, title='', action='', url='', contentType='movie'): + + itemlist.append(Item( + channel = item.channel, + title = title, + action = action, + url = url, + contentType = contentType + )) + from channelselector import thumb + itemlist = thumb(itemlist) + return itemlist \ No newline at end of file