Fixed manual auth
For now, moved back to global variables to allow manual login.
This commit is contained in:
parent
8e6610c8aa
commit
b66ac39ccc
1 changed files with 10 additions and 4 deletions
|
@ -24,24 +24,30 @@ addon = xbmcaddon.Addon(id='plugin.video.emby')
|
||||||
addondir = xbmc.translatePath(addon.getAddonInfo('profile'))
|
addondir = xbmc.translatePath(addon.getAddonInfo('profile'))
|
||||||
|
|
||||||
WINDOW = xbmcgui.Window( 10000 )
|
WINDOW = xbmcgui.Window( 10000 )
|
||||||
|
downloadUtils = DownloadUtils()
|
||||||
|
port = addon.getSetting('port')
|
||||||
|
host = addon.getSetting('ipaddress')
|
||||||
|
server = host + ":" + port
|
||||||
|
|
||||||
|
userid = downloadUtils.getUserId()
|
||||||
|
|
||||||
class PlaybackUtils():
|
class PlaybackUtils():
|
||||||
|
|
||||||
settings = None
|
settings = None
|
||||||
language = addon.getLocalizedString
|
language = addon.getLocalizedString
|
||||||
logLevel = 0
|
logLevel = 0
|
||||||
downloadUtils = DownloadUtils()
|
#downloadUtils = DownloadUtils()
|
||||||
|
|
||||||
def __init__(self, *args):
|
def __init__(self, *args):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
def PLAY(self, id):
|
def PLAY(self, id):
|
||||||
|
|
||||||
port = addon.getSetting('port')
|
'''port = addon.getSetting('port')
|
||||||
host = addon.getSetting('ipaddress')
|
host = addon.getSetting('ipaddress')
|
||||||
server = host + ":" + port
|
server = host + ":" + port
|
||||||
|
|
||||||
userid = self.downloadUtils.getUserId()
|
userid = self.downloadUtils.getUserId()'''
|
||||||
jsonData = self.downloadUtils.downloadUrl("http://" + server + "/mediabrowser/Users/" + userid + "/Items/" + id + "?format=json&ImageTypeLimit=1", suppress=False, popup=1 )
|
jsonData = self.downloadUtils.downloadUrl("http://" + server + "/mediabrowser/Users/" + userid + "/Items/" + id + "?format=json&ImageTypeLimit=1", suppress=False, popup=1 )
|
||||||
result = json.loads(jsonData)
|
result = json.loads(jsonData)
|
||||||
|
|
||||||
|
@ -335,4 +341,4 @@ class PlaybackUtils():
|
||||||
|
|
||||||
playlist.add(playurl, listItem)
|
playlist.add(playurl, listItem)
|
||||||
|
|
||||||
return True
|
return True
|
||||||
|
|
Loading…
Reference in a new issue