Ejemplo n.º 1
0
    Settings.setTvTunesId()

    # Check if the settings mean we want to reset the volume on startup
    startupVol = Settings.getStartupVolume()

    if startupVol < 0:
        log("TvTunesService: No Volume Change Required")
    else:
        log("TvTunesService: Setting volume to %s" % startupVol)
        xbmc.executebuiltin('SetVolume(%d)' % startupVol, True)

    # Check if the video info button should be hidden, we do this here as this will be
    # called when the system is loaded, it can then be read by the skin
    # when it comes to draw the button
    WindowShowing.updateHideVideoInfoButton()
    WindowShowing.updateShowOnContextMenu()

    # Make sure the user wants to play themes
    if Settings.isThemePlayingEnabled():
        log("TvTunesService: Theme playing enabled")

        if Settings.isUploadEnabled():
            log("TvTunesService: Launching uploader")
            xbmc.executebuiltin('RunScript(%s)' % os.path.join(__lib__, "upload.py"), False)
        else:
            log("TvTunesService: Uploader not enabled")

        # Create a monitor so we can reload the settings if they change
        systemMonitor = TvTunesMonitor()

        # Start looping to perform the TvTune theme operations