def start(self): ph = PluginHelpers() ph.writeLog('Starting %s V.%s' % (__addonname__, __version__)) monitor = MyMonitor() monitor.settings_initialize() ph.notifyOSD(__LS__(30010), __LS__(30106), __icon__, enabled=monitor.enableinfo) xbmc.executebuiltin('XBMC.RunScript(plugin.program.newscenter,"?methode=refresh")') while not monitor.abortRequested(): if ( monitor.waitForAbort(monitor.refreshcontent) | monitor.refreshcontent == 0 ): self.stop() break monitor.skinnermode = __addon__.getSetting('skinnermode') if monitor.skinnermode == 'True': shouldrun = WINDOW.getProperty( "LatestNews.Service" ) if shouldrun == "active": ph.notifyOSD(__LS__(30010), __LS__(30108), __icon__, enabled=monitor.enableinfo) xbmc.executebuiltin('XBMC.RunScript(plugin.program.newscenter,"?methode=refresh")') else: ph.notifyOSD(__LS__(30010), __LS__(30108), __icon__, enabled=monitor.enableinfo) xbmc.executebuiltin('XBMC.RunScript(plugin.program.newscenter,"?methode=refresh")') self.stop()
def start(self): ph = PluginHelpers() ph.writeLog('Starting %s V.%s' % (__addonname__, __version__)) monitor = MyMonitor() monitor.settings_initialize() ph.notifyOSD(__LS__(30010), __LS__(30106), __icon__, enabled=monitor.enableinfo) xbmc.executebuiltin( 'XBMC.RunScript(plugin.program.newscenter,"?methode=refresh")') while not monitor.abortRequested(): if (monitor.waitForAbort(monitor.refreshcontent) | monitor.refreshcontent == 0): self.stop() break monitor.skinnermode = __addon__.getSetting('skinnermode') if monitor.skinnermode == 'True': shouldrun = WINDOW.getProperty("LatestNews.Service") if shouldrun == "active": ph.notifyOSD(__LS__(30010), __LS__(30108), __icon__, enabled=monitor.enableinfo) xbmc.executebuiltin( 'XBMC.RunScript(plugin.program.newscenter,"?methode=refresh")' ) else: ph.notifyOSD(__LS__(30010), __LS__(30108), __icon__, enabled=monitor.enableinfo) xbmc.executebuiltin( 'XBMC.RunScript(plugin.program.newscenter,"?methode=refresh")' ) self.stop()