Skip to content

Commit

Permalink
Fixed #64
Browse files Browse the repository at this point in the history
  • Loading branch information
bigretromike committed Mar 2, 2016
1 parent 6b8274a commit 4bd37b9
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 3 deletions.
2 changes: 1 addition & 1 deletion addon.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<addon id="plugin.video.nakamoriplugin" name="Nakamori Plugin" version="1.2.9" provider-name="BigRetroMike">
<addon id="plugin.video.nakamoriplugin" name="Nakamori Plugin" version="1.3.1" provider-name="BigRetroMike">
<extension point="xbmc.python.pluginsource" library="nakamori.py">
<provides>video</provides>
</extension>
Expand Down
8 changes: 8 additions & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
v1.3.1 (02/03/2016)
- Fix the Fix for files without duration (#64) (thanks kaigame)

v1.3.0 (01/03/2016)
- Fix for files without duration (#64)
- Search is once again avaible (#68)
- Fully tested with Jarvice (Final build) (#66)

v1.2.9 (14/02/2016)
- workaround for slow connection like Android on WiFi trying to watch big H264@1080p

Expand Down
18 changes: 16 additions & 2 deletions nakamori.py
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,16 @@ def buildMainMenu():
liz.setProperty('fanart_image', fanart)
liz.setInfo( type="Video", infoLabels={ "Title": title } )
xbmcplugin.addDirectoryItem(handle,url=u,listitem=liz,isFolder=True)
util.addDir("Search", "http://" + addon.getSetting("ipaddress") + ":" + addon.getSetting("port") + "/jmmserverkodi/search/" + addon.getSetting("userid") + "/"+ addon.getSetting("maxlimit") +"/", 3, "http://" + addon.getSetting("ipaddress") + ":" + addon.getSetting("port") + "/jmmserverkodi/GetSupportImage/plex_others.png","2","3","4")
#Add Search
url = "http://" + addon.getSetting("ipaddress") + ":" + addon.getSetting("port") + "/jmmserverkodi/search/" + addon.getSetting("userid") + "/"+ addon.getSetting("maxlimit") +"/"
mode = 3
title = "Search"
thumb = "http://" + addon.getSetting("ipaddress") + ":" + addon.getSetting("port") + "/jmmserverkodi/GetSupportImage/plex_others.png"
liz=xbmcgui.ListItem(label=title, label2=title, iconImage="DefaultVideo.png", thumbnailImage=thumb, path=url)
liz.setInfo( type="Video", infoLabels={ "Title": title } )
u=sys.argv[0]+"?url="+url+"&mode="+str(mode)+"&name="+urllib.quote_plus(title)
xbmcplugin.addDirectoryItem(handle,url=u,listitem=liz,isFolder=True)
#util.addDir("Search", "http://" + addon.getSetting("ipaddress") + ":" + addon.getSetting("port") + "/jmmserverkodi/search/" + addon.getSetting("userid") + "/"+ addon.getSetting("maxlimit") +"/", 3, "http://" + addon.getSetting("ipaddress") + ":" + addon.getSetting("port") + "/jmmserverkodi/GetSupportImage/plex_others.png","2","3","4")
xbmcplugin.endOfDirectory(handle, True, False, False)

def buildTVShows(params):
Expand Down Expand Up @@ -399,7 +408,12 @@ def buildTVEpisodes(params):

#Gather some data
view_offset=atype.get('viewOffset',0)
duration=int(atype.find('Media').get('duration'))/1000
#Check for empty duration from MediaInfo check fail and handle it properly
tmp_duration = atype.find('Media').get('duration','1000')
if not tmp_duration:
duration = 1
else:
duration=int(tmp_duration)/1000
#Required listItem entries for XBMC
details={'plot' : atype.get('summary','').encode('utf-8') ,
'title' : atype.get('title','Unknown').encode('utf-8') ,
Expand Down

0 comments on commit 4bd37b9

Please sign in to comment.