add WebSocket for events and remote control

For some reason playback stop is not being reported
This commit is contained in:
faush01 2015-03-23 15:54:16 +11:00
parent 59cdfcd922
commit 9e5385c1c6
5 changed files with 398 additions and 2 deletions

View file

@ -17,6 +17,7 @@ from LibrarySync import LibrarySync
from Player import Player
from DownloadUtils import DownloadUtils
from ConnectionManager import ConnectionManager
from WebSocketClient import WebSocketThread
librarySync = LibrarySync()
class Service():
@ -37,6 +38,8 @@ class Service():
player = Player()
lastProgressUpdate = datetime.today()
newWebSocketThread = WebSocketThread()
newWebSocketThread.start()
# check kodi library sources
mayRun = utils.checkKodiSources()
@ -116,6 +119,9 @@ class Service():
xbmc.log("Not authenticated yet")
utils.logMsg("MB3 Sync Service", "stopping Service",0)
if(newWebSocketThread != None):
newWebSocketThread.stopClient()
#start the service