2020-03-07, 21:13
Hi @ronie ,
I try to turn this screensaver addon into a script addon, as you mentioned in post 694
Script is working, but when it run more than 10 minutes, dim screensaver start.
Here is mi code in default.py to make screensaver off and after script end restore screensaver settings.
I have problem with restore screensaver settings, this doesnt work ... please help
I try to turn this screensaver addon into a script addon, as you mentioned in post 694
Script is working, but when it run more than 10 minutes, dim screensaver start.
Here is mi code in default.py to make screensaver off and after script end restore screensaver settings.
I have problem with restore screensaver settings, this doesnt work ... please help
python:
if __name__ == '__main__':
log('script version %s started' % ADDONVERSION)
data = xbmc.executeJSONRPC('{ "jsonrpc": "2.0", "id": 0, "method": "Settings.getSettingValue", "params": {"setting":"screensaver.mode" } }')
xbmc.executeJSONRPC('{"jsonrpc":"2.0", "method":"Settings.SetSettingValue", "params":{"setting":"screensaver.mode", "value":""}, "id": 1}')
saver_mode = json.loads(data)
saver_mode = saver_mode['result']['value']
import gui
screensaver_gui = gui.Screensaver('script-python-slideshow.xml', CWD, 'default')
screensaver_gui.doModal()
del screensaver_gui
xbmc.executeJSONRPC('{ "jsonrpc": "2.0", "id": 2, "method":"Settings.setSettingValue", "params": {"setting":"screensaver.mode", "value" : "%s"} }' % saver_mode )
log('script stopped')