Merge branch 'master' of https://github.com/kodiondemand/addon into master
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"id": "paramount",
|
||||
"name": "Paramount Network",
|
||||
"active": true,
|
||||
"active": false,
|
||||
"language": ["ita"],
|
||||
"thumbnail": "paramount.png",
|
||||
"banner": "paramount.png",
|
||||
|
||||
@@ -84,8 +84,9 @@ class MainWindow(xbmcgui.WindowXMLDialog):
|
||||
self.getControl(CAST).addItems(self.cast)
|
||||
else:
|
||||
self.getControl(CAST).setVisible(False)
|
||||
if Info.getProperty('rating'):
|
||||
self.getControl(RATING).setText(str(Info.getProperty('rating')))
|
||||
if Info.getProperty('rating'): rating = str(Info.getProperty('rating'))
|
||||
else: rating = 'N/A'
|
||||
self.getControl(RATING).setText(rating)
|
||||
getFocus(self)
|
||||
|
||||
def onClick(self, control_id):
|
||||
@@ -102,9 +103,9 @@ class MainWindow(xbmcgui.WindowXMLDialog):
|
||||
info = self.getControl(RECOMANDED).getSelectedItem()
|
||||
self.close()
|
||||
Trailer(info)
|
||||
elif control_id in [ACTORS]:
|
||||
elif control_id in [ACTORS, CAST]:
|
||||
self.close()
|
||||
Main(self.getControl(ACTORS).getSelectedItem())
|
||||
Main(self.getControl(self.getFocusId()).getSelectedItem())
|
||||
elif control_id in [RECOMANDED] and self.getControl(RECOMANDED).getSelectedPosition() > 0:
|
||||
self.close()
|
||||
Main(self.getControl(RECOMANDED).getSelectedItem())
|
||||
|
||||
@@ -40,12 +40,12 @@
|
||||
|
||||
<!-- LOADING -->
|
||||
<control type="image" id='30011'>
|
||||
<top>310</top>
|
||||
<left>590</left>
|
||||
<width>100</width>
|
||||
<height>100</height>
|
||||
<texture>Infoplus/loading.png</texture>
|
||||
<animation effect="rotate" center="640,360" start="0" end="-360" time="5000" loop="true" condition="Control.IsVisible(30011)">Conditional</animation>
|
||||
<top>355</top>
|
||||
<left>490</left>
|
||||
<width>300</width>
|
||||
<height>10</height>
|
||||
<texture>white.png</texture>
|
||||
<animation effect="zoom" pulse ="true" center="auto" start="0,100" end="100,100" time="1000" condition="Control.IsVisible(30011)">Conditional</animation>
|
||||
</control>
|
||||
|
||||
<control type="grouplist">
|
||||
@@ -309,7 +309,7 @@
|
||||
<top>25</top>
|
||||
<right>25</right>
|
||||
<height>50</height>
|
||||
<width>220</width>
|
||||
<width>240</width>
|
||||
<visible allowhiddenfocus="true">Control.HasFocus(30500) | Control.HasFocus(30006) | Control.HasFocus(30007) | Control.HasFocus(30008)</visible>
|
||||
<control type="image">
|
||||
<width>50</width>
|
||||
@@ -318,7 +318,7 @@
|
||||
</control>
|
||||
<control type="textbox" id="30006">
|
||||
<left>60</left>
|
||||
<width>30</width>
|
||||
<width>40</width>
|
||||
<height>50</height>
|
||||
<textcolor>FFFFFFFF</textcolor>
|
||||
<shadowcolor>00000000</shadowcolor>
|
||||
@@ -328,7 +328,7 @@
|
||||
<aligny>center</aligny>
|
||||
</control>
|
||||
<control type="button" id="30007">
|
||||
<left>110</left>
|
||||
<left>120</left>
|
||||
<width>50</width>
|
||||
<height>50</height>
|
||||
<texturenofocus colordiffuse="AAFFFFFF">Infoplus/trailer.png</texturenofocus>
|
||||
@@ -338,7 +338,7 @@
|
||||
<onright>30008</onright>
|
||||
</control>
|
||||
<control type="button" id="30008">
|
||||
<left>170</left>
|
||||
<left>180</left>
|
||||
<width>50</width>
|
||||
<height>50</height>
|
||||
<texturenofocus colordiffuse="AAFFFFFF">Infoplus/search.png</texturenofocus>
|
||||
|
||||
@@ -53,7 +53,7 @@ def show_channels(item):
|
||||
|
||||
for key, channel in json['channels'].items():
|
||||
path = filetools.dirname(channel['path']) # relative path
|
||||
channel_json = load_json(channel['path']) # read channel json
|
||||
channel_json = load_json(channel) # read channel json
|
||||
|
||||
# retrieve information from json
|
||||
thumbnail = relative('thumbnail', channel_json, path)
|
||||
@@ -63,7 +63,7 @@ def show_channels(item):
|
||||
|
||||
itemlist.append(Item(channel=item.channel,
|
||||
title=support.typo(channel['channel_name'],'bold'),
|
||||
url=channel['path'],
|
||||
url=channel['url'],
|
||||
thumbnail=thumbnail,
|
||||
fanart=fanart,
|
||||
plot=plot,
|
||||
@@ -613,7 +613,7 @@ def load_json(item, no_order=False):
|
||||
url = item.url
|
||||
filterkey = item.filterkey
|
||||
else:
|
||||
url = item
|
||||
url = item['url'] if 'url' in item else item
|
||||
filterkey = ''
|
||||
try:
|
||||
if url.startswith('http'):
|
||||
@@ -639,9 +639,10 @@ def load_and_check(item):
|
||||
json = jsontools.load(file.read())
|
||||
|
||||
for key, channel in json['channels'].items():
|
||||
if not 'checked' in channel:
|
||||
if not 'check' in channel:
|
||||
response = httptools.downloadpage(channel['path'], follow_redirects=True, timeout=5)
|
||||
if response.success:
|
||||
channel['url'] = channel['path']
|
||||
channel['path'] = response.url
|
||||
channel['channel_name'] = re.sub(r'\[[^\]]+\]', '', channel['channel_name'])
|
||||
channel['check'] = True
|
||||
|
||||
@@ -66,37 +66,6 @@
|
||||
"@70014"
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "label1",
|
||||
"type": "label",
|
||||
"label": "",
|
||||
"enabled": false,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"id": "filmaff",
|
||||
"type": "list",
|
||||
"label": "@70428",
|
||||
"default": 0,
|
||||
"enabled": true,
|
||||
"visible": true,
|
||||
"lvalues": [
|
||||
"auto",
|
||||
"@70429",
|
||||
"@70430",
|
||||
"@70431",
|
||||
"@70432",
|
||||
"@70433",
|
||||
"@70434"
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "label2",
|
||||
"type": "label",
|
||||
"label": "",
|
||||
"enabled": false,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"id": "usuariomal",
|
||||
"type": "text",
|
||||
|
||||
Reference in New Issue
Block a user