Added tv tunes compatibility

Automatically set the proper path for tv tunes
This commit is contained in:
angelblue05 2015-06-17 01:57:09 -05:00
parent 7b041d8795
commit 56c2c9aef2

View file

@ -144,6 +144,14 @@ def getThemeMedia():
playback = "DirectStream" playback = "DirectStream"
else:return else:return
# Set custom path for user
tvtunes_path = xbmc.translatePath("special://profile/addon_data/script.tvtunes/")
if xbmcvfs.exists(tvtunes_path):
tvtunes = xbmcaddon.Addon(id="script.tvtunes")
tvtunes.setSetting('custom_path_enable', "true")
tvtunes.setSetting('custom_path', library)
xbmc.log("TV Tunes custom path is enabled and set.")
# Create library directory # Create library directory
if not xbmcvfs.exists(library): if not xbmcvfs.exists(library):
xbmcvfs.mkdir(library) xbmcvfs.mkdir(library)