Пример #1
0
def housekeepingExtensionsmenu(configentry, force=False):
    if force or (epgrefresh != None and not epgrefresh.isRunning()):
        PlugDescriptor = None
        if configentry == config.plugins.epgrefresh.show_in_extensionsmenu:
            PlugDescriptor = extSetupDescriptor
        elif configentry == config.plugins.epgrefresh.show_run_in_extensionsmenu:
            PlugDescriptor = extRunDescriptor
        if PlugDescriptor != None:
            AdjustExtensionsmenu(configentry.value, PlugDescriptor)
Пример #2
0
def housekeepingExtensionsmenu(configentry, force=False):
	if force or (epgrefresh != None and not epgrefresh.isRunning()):
		PlugDescriptor = None
		if configentry == config.plugins.epgrefresh.show_in_extensionsmenu:
			PlugDescriptor = extSetupDescriptor
		elif configentry == config.plugins.epgrefresh.show_run_in_extensionsmenu:
			PlugDescriptor = extRunDescriptor
		if PlugDescriptor != None:
			AdjustExtensionsmenu(configentry.value, PlugDescriptor)
Пример #3
0
def manualrefresh_menu(menuid, **kwargs):
    if menuid == "mainmenu" and config.plugins.epgrefresh.stop_on_mainmenu.value and epgrefresh.isRunning(
    ):
        return [(_("Stop Running EPG-refresh"), stop_Running,
                 "stop_EPG-refresh", 99)]
    elif menuid == "mainmenu" and config.plugins.epgrefresh.start_on_mainmenu.value and not epgrefresh.isRunning(
    ):
        return [(_("EPG-refresh now"), start_Running, "start_EPG-refresh", 99)]
    return []
	def __init__(self, session):
		if epgrefresh.isRunning():
			menu = [(_("Stop running refresh"), boundFunction(self.close, self.FUNCTION_RETURN_STOPREFRESH)),
				(_("Pending Services"), boundFunction(self.close, self.FUNCTION_RETURN_SHOWPENDING))]
		else:
			menu = [(_("Refresh now"), boundFunction(self.close, self.FUNCTION_RETURN_FORCEREFRESH))]
		menu.append((_("Cancel"), self.close))

		FixedMenu.__init__(self, session, _("EPGRefresh Functions"), menu)
		self.skinName = ["EPGRefreshConfigurationFunctionContextMenu", "Menu" ]
	def __init__(self, session):
		if epgrefresh.isRunning():
			menu = [(_("Stop running refresh"), boundFunction(self.close, self.FUNCTION_RETURN_STOPREFRESH)),
				(_("Pending Services"), boundFunction(self.close, self.FUNCTION_RETURN_SHOWPENDING))]
		else:
			menu = [(_("Refresh now"), boundFunction(self.close, self.FUNCTION_RETURN_FORCEREFRESH))]
		menu.append((_("Cancel"), self.close))

		FixedMenu.__init__(self, session, _("EPGRefresh Functions"), menu)
		self.skinName = ["EPGRefreshConfigurationFunctionContextMenu", "Menu" ]
Пример #6
0
def start_Running(session, **kwargs):
	if epgrefresh.isRunning():
		return True
	epgrefresh.forceRefresh(session, dontshutdown=True)
Пример #7
0
def stop_Running(session, **kwargs):
	if not epgrefresh.isRunning():
		return True
	epgrefresh.showPendingServices(session)
Пример #8
0
def manualrefresh_menu(menuid, **kwargs):
	if menuid == "mainmenu" and config.plugins.epgrefresh.stop_on_mainmenu.value and epgrefresh.isRunning():
		return [(_("Stop Running EPG-refresh"), stop_Running, "stop_EPG-refresh", 99)]
	elif menuid == "mainmenu" and config.plugins.epgrefresh.start_on_mainmenu.value and not epgrefresh.isRunning():
		return [(_("EPG-refresh now"), start_Running, "start_EPG-refresh", 99)]
	return []
Пример #9
0
def _startAfterConfig(session):
    if config.plugins.epgrefresh.enabled.value:
        if not epgrefresh.isRunning():
            epgrefresh.start(session)
Пример #10
0
def _startAfterConfig(session):
    if config.plugins.epgrefresh.enabled.value:
        if not epgrefresh.isRunning():
            epgrefresh.start(session)