-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathaddon.py
More file actions
54 lines (40 loc) · 1.56 KB
/
Copy pathaddon.py
File metadata and controls
54 lines (40 loc) · 1.56 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
from xbmcswift2 import Plugin, xbmcgui
from resources.lib import theinterceptspokenedition
plugin = Plugin()
URL0 = "http://api.spokenlayer.com/feed/channel/v1-intercept-news2-ext/3c9929b72538c12bd92ac6762f8d798b9d4e8cdca7692ea74f466061d01816cb"
@plugin.route('/')
def main_menu():
"""
main menu
"""
items = [
{
'label': plugin.get_string(20000),
'path': plugin.url_for('spoken_edition'),
'thumbnail': "http://media.spokenlayer.com/cover-art/2016/10/01/the-intercept-v2-10-1-1400x1400.png"},
{
'label': plugin.get_string(20001),
'path': plugin.url_for('spoken_edition1'),
'thumbnail': "http://media.spokenlayer.com/cover-art/2016/10/01/the-intercept-v2-10-1-1400x1400.png"},
]
return items
@plugin.route('/spoken_edition/')
def spoken_edition():
"""
contains playable podcasts listed as just-in
"""
soup0 = theinterceptspokenedition.get_soup0(URL0)
playable_podcast0 = theinterceptspokenedition.get_playable_podcast0(soup0)
items = theinterceptspokenedition.compile_playable_podcast0(playable_podcast0)
return items
@plugin.route('/spoken_edition1/')
def spoken_edition1():
"""
contains playable podcasts listed as just-in
"""
soup0 = theinterceptspokenedition.get_soup0(URL0)
playable_podcast01 = theinterceptspokenedition.get_playable_podcast01(soup0)
items = theinterceptspokenedition.compile_playable_podcast01(playable_podcast01)
return items
if __name__ == '__main__':
plugin.run()