Nome server Directo nelle traduzioni
This commit is contained in:
@@ -110,7 +110,7 @@ def findvideos(item):
|
|||||||
for title, url in matches:
|
for title, url in matches:
|
||||||
get_video_list(url, title, itemlist)
|
get_video_list(url, title, itemlist)
|
||||||
else:
|
else:
|
||||||
get_video_list(item.url, 'Diretto', itemlist)
|
get_video_list(item.url, support.config.get_localized_string(30137), itemlist)
|
||||||
return support.server(item, itemlist=itemlist)
|
return support.server(item, itemlist=itemlist)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -149,6 +149,6 @@ def findvideos(item):
|
|||||||
if url.startswith('//'): url = 'https:' + url
|
if url.startswith('//'): url = 'https:' + url
|
||||||
elif url.startswith('/'): url = 'https:/' + url
|
elif url.startswith('/'): url = 'https:/' + url
|
||||||
if 'vvvvid' in url: itemlist.append(item.clone(action="play", title='VVVVID', url=url, server='vvvvid'))
|
if 'vvvvid' in url: itemlist.append(item.clone(action="play", title='VVVVID', url=url, server='vvvvid'))
|
||||||
else: itemlist.append(item.clone(action="play", title='Diretto', url=url, server='directo'))
|
else: itemlist.append(item.clone(action="play", title=support.config.get_localized_string(30137), url=url, server='directo'))
|
||||||
|
|
||||||
return support.server(item, itemlist=itemlist)
|
return support.server(item, itemlist=itemlist)
|
||||||
|
|||||||
@@ -219,4 +219,4 @@ def episodios(item):
|
|||||||
|
|
||||||
def findvideos(item):
|
def findvideos(item):
|
||||||
support.log()
|
support.log()
|
||||||
return support.server(item,itemlist=[item.clone(title='Diretto', server='directo', action='play')])
|
return support.server(item,itemlist=[item.clone(title=support.config.get_localized_string(30137), server='directo', action='play')])
|
||||||
@@ -111,7 +111,7 @@ def findvideos(item):
|
|||||||
for title, url in matches:
|
for title, url in matches:
|
||||||
get_video_list(url, title, itemlist)
|
get_video_list(url, title, itemlist)
|
||||||
else:
|
else:
|
||||||
get_video_list(item.url, 'Diretto', itemlist)
|
get_video_list(item.url, support.config.get_localized_string(30137), itemlist)
|
||||||
return support.server(item, itemlist=itemlist)
|
return support.server(item, itemlist=itemlist)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -68,7 +68,7 @@ def findvideos(item):
|
|||||||
matches = support.match(item, patron=r'filename: "(.*?)"').matches
|
matches = support.match(item, patron=r'filename: "(.*?)"').matches
|
||||||
|
|
||||||
for url in matches:
|
for url in matches:
|
||||||
itemlist.append(item.clone(action="play", title='Diretto', server='directo', url=host + url))
|
itemlist.append(item.clone(action="play", title=support.config.get_localized_string(30137), server='directo', url=host + url))
|
||||||
|
|
||||||
return support.server(item, itemlist=itemlist)
|
return support.server(item, itemlist=itemlist)
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -288,7 +288,7 @@ def findvideos(item):
|
|||||||
else:
|
else:
|
||||||
url = item.url
|
url = item.url
|
||||||
|
|
||||||
itemlist.append(item.clone(server = 'directo', title = 'Diretto', fanart = item.json, url = getUrl(url), action = 'play' ))
|
itemlist.append(item.clone(server = 'directo', title = support.config.get_localized_string(30137), fanart = item.json, url = getUrl(url), action = 'play' ))
|
||||||
return support.server(item, itemlist=itemlist, Download=False)
|
return support.server(item, itemlist=itemlist, Download=False)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -179,5 +179,5 @@ def findvideos(item):
|
|||||||
url = support.match(support.match(item).data.replace('"','"').replace('\\',''), patron=r'video_url"\s*:\s*"([^"]+)"').match
|
url = support.match(support.match(item).data.replace('"','"').replace('\\',''), patron=r'video_url"\s*:\s*"([^"]+)"').match
|
||||||
playlist = support.match(url, patron=r'\./([^.]+)').matches
|
playlist = support.match(url, patron=r'\./([^.]+)').matches
|
||||||
for res in playlist:
|
for res in playlist:
|
||||||
itemlist.append(item.clone(title='Diretto', server='directo', url=url.replace('playlist',res), quality=res, action='play'))
|
itemlist.append(item.clone(title=support.config.get_localized_string(30137), server='directo', url=url.replace('playlist',res), quality=res, action='play'))
|
||||||
return support.server(item, itemlist=itemlist)
|
return support.server(item, itemlist=itemlist)
|
||||||
+11
-5
@@ -191,7 +191,7 @@ def findvideosbyserver(data, serverid):
|
|||||||
for x in range(len(match.groups())):
|
for x in range(len(match.groups())):
|
||||||
url = url.replace("\\%s" % (x + 1), match.groups()[x])
|
url = url.replace("\\%s" % (x + 1), match.groups()[x])
|
||||||
msg += "\nfound url: %s" % url
|
msg += "\nfound url: %s" % url
|
||||||
value = server_parameters["name"], url, serverid, server_parameters.get("thumbnail", "")
|
value = translate_server_name(server_parameters["name"]) , url, serverid, server_parameters.get("thumbnail", "")
|
||||||
if value not in devuelve and url not in server_parameters["find_videos"].get("ignore_urls", []):
|
if value not in devuelve and url not in server_parameters["find_videos"].get("ignore_urls", []):
|
||||||
devuelve.append(value)
|
devuelve.append(value)
|
||||||
logger.info(msg)
|
logger.info(msg)
|
||||||
@@ -235,7 +235,7 @@ def get_server_from_url(url):
|
|||||||
for x in range(len(match.groups())):
|
for x in range(len(match.groups())):
|
||||||
url = url.replace("\\%s" % (x + 1), match.groups()[x])
|
url = url.replace("\\%s" % (x + 1), match.groups()[x])
|
||||||
msg += "\nurl encontrada: %s" % url
|
msg += "\nurl encontrada: %s" % url
|
||||||
value = server_parameters["name"], url, serverid, server_parameters.get("thumbnail", "")
|
value = translate_server_name(server_parameters["name"]), url, serverid, server_parameters.get("thumbnail", "")
|
||||||
if url not in server_parameters["find_videos"].get("ignore_urls", []):
|
if url not in server_parameters["find_videos"].get("ignore_urls", []):
|
||||||
logger.info(msg)
|
logger.info(msg)
|
||||||
return value
|
return value
|
||||||
@@ -274,7 +274,7 @@ def resolve_video_urls_for_playing(server, url, video_password="", muestra_dialo
|
|||||||
if isinstance(video_password, list):
|
if isinstance(video_password, list):
|
||||||
return video_password, len(video_password) > 0, "<br/>".join(error_messages)
|
return video_password, len(video_password) > 0, "<br/>".join(error_messages)
|
||||||
logger.info("Server: %s, url is good" % server)
|
logger.info("Server: %s, url is good" % server)
|
||||||
video_urls.append(["%s [%s]" % (urlparse.urlparse(url)[2][-4:], server), url])
|
video_urls.append(["%s [%s]" % (urlparse.urlparse(url)[2][-4:], config.get_localized_string(30137)), url])
|
||||||
|
|
||||||
# Find out the video URL
|
# Find out the video URL
|
||||||
else:
|
else:
|
||||||
@@ -286,7 +286,7 @@ def resolve_video_urls_for_playing(server, url, video_password="", muestra_dialo
|
|||||||
if server_parameters:
|
if server_parameters:
|
||||||
# Show a progress dialog
|
# Show a progress dialog
|
||||||
if muestra_dialogo:
|
if muestra_dialogo:
|
||||||
progreso = (platformtools.dialog_progress_bg if background_dialog else platformtools.dialog_progress)(config.get_localized_string(20000), config.get_localized_string(70180) % server_parameters["name"])
|
progreso = (platformtools.dialog_progress_bg if background_dialog else platformtools.dialog_progress)(config.get_localized_string(20000), config.get_localized_string(70180) % translate_server_name(server_parameters["name"]))
|
||||||
|
|
||||||
# Count the available options, to calculate the percentage
|
# Count the available options, to calculate the percentage
|
||||||
|
|
||||||
@@ -346,7 +346,7 @@ def resolve_video_urls_for_playing(server, url, video_password="", muestra_dialo
|
|||||||
# Own free and premium option uses the same server
|
# Own free and premium option uses the same server
|
||||||
if opcion == "free" or opcion == server:
|
if opcion == "free" or opcion == server:
|
||||||
serverid = server_module
|
serverid = server_module
|
||||||
server_name = server_parameters["name"]
|
server_name = translate_server_name(server_parameters["name"])
|
||||||
|
|
||||||
# Rest of premium options use a debrider
|
# Rest of premium options use a debrider
|
||||||
else:
|
else:
|
||||||
@@ -788,3 +788,9 @@ def check_video_link(item, timeout=3):
|
|||||||
|
|
||||||
logger.info("[check_video_link] There is no test_video_exists for server: %s" % server)
|
logger.info("[check_video_link] There is no test_video_exists for server: %s" % server)
|
||||||
return item, NK
|
return item, NK
|
||||||
|
|
||||||
|
def translate_server_name(name):
|
||||||
|
if '@' in name:
|
||||||
|
return config.get_localized_string(int(name.replace('@','')))
|
||||||
|
else:
|
||||||
|
return name
|
||||||
+1
-1
@@ -1177,7 +1177,7 @@ def server(item, data='', itemlist=[], headers='', AutoPlay=True, CheckLinks=Tru
|
|||||||
log(findS)
|
log(findS)
|
||||||
if not findS:
|
if not findS:
|
||||||
if item.channel == 'community':
|
if item.channel == 'community':
|
||||||
findS= ('Diretto', videoitem.url, 'directo')
|
findS= (support.config.get_localized_string(30137), videoitem.url, 'directo')
|
||||||
else:
|
else:
|
||||||
videoitem.url = unshortenit.unshorten_only(videoitem.url)[0]
|
videoitem.url = unshortenit.unshorten_only(videoitem.url)[0]
|
||||||
findS = servertools.get_server_from_url(videoitem.url)
|
findS = servertools.get_server_from_url(videoitem.url)
|
||||||
|
|||||||
@@ -1113,7 +1113,7 @@ def install_widevine():
|
|||||||
path = xbmc.translatePath(Addon('inputstream.adaptive').getSetting('DECRYPTERPATH'))
|
path = xbmc.translatePath(Addon('inputstream.adaptive').getSetting('DECRYPTERPATH'))
|
||||||
|
|
||||||
# if Widevine CDM is not installed
|
# if Widevine CDM is not installed
|
||||||
if not os.path.exists(path):
|
if not os.path.exists(path) or not os.path.listdir(path):
|
||||||
select = dialog_yesno('Widevine CDM', config.get_localized_string(70808))
|
select = dialog_yesno('Widevine CDM', config.get_localized_string(70808))
|
||||||
if select > 0:
|
if select > 0:
|
||||||
if not 'arm' in platform['arch']:
|
if not 'arm' in platform['arch']:
|
||||||
|
|||||||
@@ -44,7 +44,7 @@
|
|||||||
},
|
},
|
||||||
"free": true,
|
"free": true,
|
||||||
"id": "directo",
|
"id": "directo",
|
||||||
"name": "Direct",
|
"name": "@30137",
|
||||||
"settings": [
|
"settings": [
|
||||||
{
|
{
|
||||||
"default": false,
|
"default": false,
|
||||||
|
|||||||
Reference in New Issue
Block a user