From 437c47868b586817cebbc42b29ab65db9e52a0ef Mon Sep 17 00:00:00 2001 From: Alhaziel <46535975+lozioangie@users.noreply.github.com> Date: Sun, 25 Aug 2019 19:07:51 +0200 Subject: [PATCH] Download rimosso da videoteca --- core/support.py | 54 +++++++++++++++++------------------ platformcode/platformtools.py | 2 +- specials/favorites.py | 2 +- 3 files changed, 28 insertions(+), 30 deletions(-) diff --git a/core/support.py b/core/support.py index f75d0e5e..bb4bfa58 100644 --- a/core/support.py +++ b/core/support.py @@ -747,37 +747,35 @@ def download(itemlist, item, typography='', function_level=1, function=''): contentSerieName=item.contentSerieName if item.contentSerieName else '' contentTitle=item.contentTitle if item.contentTitle else '' - # if item.contentType != 'episode': - log(item) - itemlist.append( - Item(channel='downloads', - fromchannel=item.channel, - title=title, - fulltitle=item.fulltitle, - show=item.fulltitle, - contentType=item.contentType, - contentSerieName=contentSerieName, - url=item.url, - action='save_download', - fromaction=fromaction, - contentTitle=contentTitle - )) - if fromaction == 'episodios': + if item.contentChannel != 'videolibrary': itemlist.append( Item(channel='downloads', - fromchannel=item.channel, - title=typo(config.get_localized_string(60357),typography), - fulltitle=item.fulltitle, - show=item.fulltitle, - contentType=item.contentType, - contentSerieName=contentSerieName, - url=item.url, - action='save_download', - fromaction=fromaction, - contentTitle=contentTitle, - download='season' + fromchannel=item.channel, + title=title, + fulltitle=item.fulltitle, + show=item.fulltitle, + contentType=item.contentType, + contentSerieName=contentSerieName, + url=item.url, + action='save_download', + fromaction=fromaction, + contentTitle=contentTitle )) - + if fromaction == 'episodios': + itemlist.append( + Item(channel='downloads', + fromchannel=item.channel, + title=typo(config.get_localized_string(60357),typography), + fulltitle=item.fulltitle, + show=item.fulltitle, + contentType=item.contentType, + contentSerieName=contentSerieName, + url=item.url, + action='save_download', + fromaction=fromaction, + contentTitle=contentTitle, + download='season' + )) return itemlist diff --git a/platformcode/platformtools.py b/platformcode/platformtools.py index 0ef975e5..e3c3a77c 100644 --- a/platformcode/platformtools.py +++ b/platformcode/platformtools.py @@ -596,7 +596,7 @@ def set_context_commands(item, parent_item): (sys.argv[0], item.clone(action="add_pelicula_to_library", from_action=item.action).tourl()))) - if item.channel != "downloads" and downloadenabled != "false": + if item.channel != "downloads" and item.channel != "videolibrary" and downloadenabled != "false": # Descargar pelicula if item.contentType == "movie": context_commands.append((config.get_localized_string(60354), "XBMC.RunPlugin(%s?%s)" % diff --git a/specials/favorites.py b/specials/favorites.py index 38a997bd..f12e7944 100644 --- a/specials/favorites.py +++ b/specials/favorites.py @@ -49,7 +49,7 @@ def mainlist(item): "action": "delFavourite", "channel": "favorites", "from_title": item.title}, - {"title": "Renombrar", + {"title": config.get_localized_string(70278), # Rename "action": "renameFavourite", "channel": "favorites", "from_title": item.title}