Permalink
Browse files

always resume episodes and movies

  • Loading branch information...
1 parent 0f4f71f commit ce877081f25c194cc837aa341134b7bc28ac7112 @MartijnKaijser MartijnKaijser committed Nov 14, 2012
Showing with 5 additions and 8 deletions.
  1. +1 −1 addon.xml
  2. +1 −4 changelog.txt
  3. +3 −3 default.py
View
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<addon id="service.skin.widgets" name="Skin Widgets" version="0.0.13" provider-name="Martijn">
+<addon id="service.skin.widgets" name="Skin Widgets" version="0.0.11" provider-name="Martijn">
<requires>
<import addon="xbmc.addon" version="11.9.7"/>
<import addon="xbmc.python" version="2.1"/>
View
@@ -1,8 +1,5 @@
-v0.0.12
-- Use the correct way to play media by using JSON-RPC
-
v0.0.11
-- Add missng landscape for tvshows
+- Always resume episodes and movies
v0.0.10
- Drop old artwork labels for tvshows and movies
View
@@ -48,9 +48,9 @@ def __init__(self):
self._parse_argv()
# check how we were executed
if self.MOVIEID:
- xbmc.executeJSONRPC('{ "jsonrpc": "2.0", "method": "Player.Open", "params": { "item": { "movieid": %d } }, "id": 1 }' % int(self.MOVIEID))
+ xbmc.executeJSONRPC('{ "jsonrpc": "2.0", "method": "Player.Open", "params": { "item": { "movieid": %d }, "options":{ "resume": true } }, "id": 1 }' % int(self.MOVIEID))
elif self.EPISODEID:
- xbmc.executeJSONRPC('{ "jsonrpc": "2.0", "method": "Player.Open", "params": { "item": { "episodeid": %d } }, "id": 1 }' % int(self.EPISODEID))
+ xbmc.executeJSONRPC('{ "jsonrpc": "2.0", "method": "Player.Open", "params": { "item": { "episodeid": %d }, "options":{ "resume": true } }, "id": 1 }' % int(self.EPISODEID))
elif self.MUSICVIDEOID:
xbmc.executeJSONRPC('{ "jsonrpc": "2.0", "method": "Player.Open", "params": { "item": { "musicvideoid": %d } }, "id": 1 }' % int(self.MUSICVIDEOID))
elif self.ALBUMID:
@@ -452,8 +452,8 @@ def _fetch_song(self, request):
count = 0
for item in jsonobject['result']['songs']:
count += 1
- path = media_path(item['file'])
play = 'XBMC.RunScript(' + __addonid__ + ',songid=' + str(item.get('songid')) + ')'
+ path = media_path(item['file'])
self.WINDOW.setProperty("%s.%d.Title" % (request, count), item['title'])
self.WINDOW.setProperty("%s.%d.Artist" % (request, count), " / ".join(item['artist']))
self.WINDOW.setProperty("%s.%d.Year" % (request, count), str(item['year']))

0 comments on commit ce87708

Please sign in to comment.