--- misc/xbmc/plugin.video.todic/default.py 2019/02/28 11:12:40 3252 +++ misc/xbmc/plugin.video.todic/default.py 2019/03/12 20:23:54 3260 @@ -3,7 +3,7 @@ ''' Todic plugin for XBMC - Version 1.7.3 + Version 1.8.2 ''' import sys @@ -27,6 +27,7 @@ __entrypoint__ = __addon__.getSetting('entrypoint').lower() __backend__ = "https://todic.dk/xbmc.php?xbmckey=" + __key__ + if __entrypoint__ == "alternative": __backend__ = "https://alt.todic.dk/xbmc.php?xbmckey=" + __key__ @@ -35,7 +36,7 @@ print( "[Todic] entrypoint: " + __entrypoint__ ) print( "[Todic] backend: " + __backend__ ) - +print( "[Todic] version: " + __addon__.getAddonInfo('version') ) fanartImage = os.path.join(__addon__.getAddonInfo('path'), 'movie_bg_blur.jpg') datapath = xbmc.translatePath( @@ -214,8 +215,11 @@ def rootMenu(): + kodi_ver = xbmc.getInfoLabel('System.BuildVersion') + plugin_ver = __addon__.getAddonInfo('version') + msgurl = __backend__ + "&action=messages&kodi=" + urllib.quote_plus(kodi_ver) + "&todicplugin=" + urllib.quote_plus(plugin_ver) - msg = open_url(__backend__ + "&action=messages") + msg = open_url(msgurl) msg = msg.strip() if msg != "": @@ -278,14 +282,17 @@ # print "url:" + url # print "thumb:" + thumb listitem = xbmcgui.ListItem( - label=name, label2='test', iconImage='DefaultFolder.png', thumbnailImage=thumb) + label=name, label2='test', iconImage='DefaultFolder.png') listitem.setProperty('Fanart_Image', fanartImage) listitem.addContextMenuItems([('Refresh', 'Container.Refresh')]) + listitem.setArt( {'thumb': thumb} ) if mode == '50': infoLabels = {} infoLabels['title'] = name infoLabels['playcount'] = playcount +# if playcount > 0: +# listitem.setArt( {'thumb': thumb} ) #not pretty - but at least we can show a different icon for unwatched/watched in kodi18 listitem.setInfo('video', infoLabels) name = name.encode('UTF-8')