diff --git a/resources/lib/constants.py b/resources/lib/constants.py index 115a9de..5830ced 100644 --- a/resources/lib/constants.py +++ b/resources/lib/constants.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- from codequick.utils import urljoin_partial import os -import xbmc +import xbmcvfs import xbmcaddon ADDON = xbmcaddon.Addon() @@ -13,12 +13,12 @@ PLAY_URL = "plugin://plugin.video.jiotv/resources/lib/main/play/?" PLAY_EX_URL = "plugin://plugin.video.jiotv/resources/lib/main/play_ex/?_pickle_=" FEATURED_SRC = "https://tv.media.jio.com/apis/v1.6/getdata/featurednew?start=0&limit=30&langId=6" -EXTRA_CHANNELS = os.path.join(xbmc.translatePath( +EXTRA_CHANNELS = os.path.join(xbmcvfs.translatePath( ADDON.getAddonInfo("path")), "resources", "extra", "channels.json") -CHANNELS_SRC = "http://jiotv.data.cdn.jio.com/apis/v1.3/getMobileChannelList/get/?os=android&devicetype=phone&version=6.0.5" +CHANNELS_SRC = "http://jiotv.data.cdn.jio.com/apis/v1.3/getMobileChannelList/get/?os=android&devicetype=phone&version=7.0.5" GET_CHANNEL_URL = "https://tv.media.jio.com/apis/v1.4/getchannelurl/getchannelurl?langId=6&userLanguages=All" CATCHUP_SRC = "http://jiotv.data.cdn.jio.com/apis/v1.3/getepg/get?offset={0}&channel_id={1}&langId=6" -M3U_SRC = os.path.join(xbmc.translatePath( +M3U_SRC = os.path.join(xbmcvfs.translatePath( ADDON.getAddonInfo("profile")), "playlist.m3u") M3U_CHANNEL = "\n#EXTINF:0 tvg-id=\"{tvg_id}\" tvg-name=\"{channel_name}\" group-title=\"{group_title}\" tvg-chno=\"{tvg_chno}\" tvg-logo=\"{tvg_logo}\"{catchup},{channel_name}\n{play_url}" EPG_SRC = "https://kodi.botallen.com/tv/epg.xml" diff --git a/resources/lib/main.py b/resources/lib/main.py index 1e50c07..cf41c5f 100644 --- a/resources/lib/main.py +++ b/resources/lib/main.py @@ -3,7 +3,8 @@ # xbmc imports from xbmcaddon import Addon -from xbmc import executebuiltin, translatePath +from xbmc import executebuiltin +from xbmcvfs import translatePath from xbmcgui import ListItem, Dialog, DialogProgress # codequick imports