Compatibility with latest Kodi Krypton. Fixes #80
This commit is contained in:
parent
991a808403
commit
900290c75a
3 changed files with 36 additions and 10 deletions
|
@ -2150,6 +2150,24 @@ class Music(Items):
|
||||||
artist_edb = emby_db.getItem_byId(artist_eid)
|
artist_edb = emby_db.getItem_byId(artist_eid)
|
||||||
artistid = artist_edb[0]
|
artistid = artist_edb[0]
|
||||||
finally:
|
finally:
|
||||||
|
if self.kodiversion >= 17:
|
||||||
|
# Kodi Krypton
|
||||||
|
query = (
|
||||||
|
'''
|
||||||
|
INSERT OR REPLACE INTO song_artist(idArtist, idSong, idRole, iOrder, strArtist)
|
||||||
|
VALUES (?, ?, ?, ?, ?)
|
||||||
|
'''
|
||||||
|
)
|
||||||
|
kodicursor.execute(query,(artistid, songid, 1, index, artist_name))
|
||||||
|
# May want to look into only doing this once?
|
||||||
|
query = (
|
||||||
|
'''
|
||||||
|
INSERT OR REPLACE INTO role(idRole, strRole)
|
||||||
|
VALUES (?, ?)
|
||||||
|
'''
|
||||||
|
)
|
||||||
|
kodicursor.execute(query, (1, 'Composer'))
|
||||||
|
else:
|
||||||
query = (
|
query = (
|
||||||
'''
|
'''
|
||||||
INSERT OR REPLACE INTO song_artist(idArtist, idSong, iOrder, strArtist)
|
INSERT OR REPLACE INTO song_artist(idArtist, idSong, iOrder, strArtist)
|
||||||
|
|
|
@ -394,7 +394,7 @@ def getKodiVideoDBPath():
|
||||||
"14": 90, # Helix
|
"14": 90, # Helix
|
||||||
"15": 93, # Isengard
|
"15": 93, # Isengard
|
||||||
"16": 99, # Jarvis
|
"16": 99, # Jarvis
|
||||||
"17": 106 # Krypton
|
"17": 107 # Krypton
|
||||||
}
|
}
|
||||||
|
|
||||||
dbPath = tryDecode(xbmc.translatePath(
|
dbPath = tryDecode(xbmc.translatePath(
|
||||||
|
|
|
@ -249,6 +249,10 @@ class VideoNodes(object):
|
||||||
|
|
||||||
if mediatype == "photos":
|
if mediatype == "photos":
|
||||||
windowpath = "ActivateWindow(Pictures,%s,return)" % path
|
windowpath = "ActivateWindow(Pictures,%s,return)" % path
|
||||||
|
else:
|
||||||
|
if self.kodiversion >= 17:
|
||||||
|
# Krypton
|
||||||
|
windowpath = "ActivateWindow(Videos,%s,return)" % path
|
||||||
else:
|
else:
|
||||||
windowpath = "ActivateWindow(Video,%s,return)" % path
|
windowpath = "ActivateWindow(Video,%s,return)" % path
|
||||||
|
|
||||||
|
@ -370,6 +374,10 @@ class VideoNodes(object):
|
||||||
"special://profile/library/video/"))
|
"special://profile/library/video/"))
|
||||||
nodeXML = "%splex_%s.xml" % (nodepath, cleantagname)
|
nodeXML = "%splex_%s.xml" % (nodepath, cleantagname)
|
||||||
path = "library://video/plex_%s.xml" % cleantagname
|
path = "library://video/plex_%s.xml" % cleantagname
|
||||||
|
if self.kodiversion >= 17:
|
||||||
|
# Krypton
|
||||||
|
windowpath = "ActivateWindow(Videos,%s,return)" % path
|
||||||
|
else:
|
||||||
windowpath = "ActivateWindow(Video,%s,return)" % path
|
windowpath = "ActivateWindow(Video,%s,return)" % path
|
||||||
|
|
||||||
# Create the video node directory
|
# Create the video node directory
|
||||||
|
|
Loading…
Reference in a new issue