Rename WHERE_SETUP to WHERE_MENU and patch all local plugins to follow this (patch...
authorFelix Domke <tmbinc@elitedvb.net>
Sun, 7 Oct 2007 10:35:19 +0000 (10:35 +0000)
committerFelix Domke <tmbinc@elitedvb.net>
Sun, 7 Oct 2007 10:35:19 +0000 (10:35 +0000)
lib/python/Components/PluginComponent.py
lib/python/Plugins/Extensions/MediaPlayer/plugin.py
lib/python/Plugins/Plugin.py
lib/python/Plugins/SystemPlugins/PositionerSetup/plugin.py
lib/python/Plugins/SystemPlugins/SatelliteEquipmentControl/plugin.py
lib/python/Plugins/SystemPlugins/Satfinder/plugin.py
lib/python/Plugins/SystemPlugins/SkinSelector/plugin.py

index 44fe896a4e4884f3c88ca63866bc5a778b5fe272..590f428dd9e689ec35b804dbdf05f592ad093c98 100644 (file)
@@ -101,7 +101,7 @@ class PluginComponent:
 
        def getPluginsForMenu(self, menuid):
                res = [ ]
-               for p in self.getPlugins(PluginDescriptor.WHERE_SETUP):
+               for p in self.getPlugins(PluginDescriptor.WHERE_MENU):
                        res += p(menuid)
                return res
 
index 0de820c84189591246b7ea1cf2ef7fe2337cb222..3207c09c3a2fe4b3e49ed1bd8cd97644c07b65c9 100644 (file)
@@ -750,6 +750,6 @@ def filescan(**kwargs):
 from Plugins.Plugin import PluginDescriptor
 def Plugins(**kwargs):
        return [
-               PluginDescriptor(name = "MediaPlayer", description = "Play back media files", where = PluginDescriptor.WHERE_SETUP, fnc = menu),
+               PluginDescriptor(name = "MediaPlayer", description = "Play back media files", where = PluginDescriptor.WHERE_MENU, fnc = menu),
                PluginDescriptor(name = "MediaPlayer", where = PluginDescriptor.WHERE_FILESCAN, fnc = filescan)
        ]
index b80dcadcf12189cd655aa12dac78191bd283e5ba..a2ee9fefad88f78a444b2f12180ac0972d4ddfe0 100644 (file)
@@ -22,8 +22,8 @@ class PluginDescriptor:
        WHERE_PLUGINMENU  = 2
        # argument: session, serviceref (currently selected)
        WHERE_MOVIELIST = 3
-       # ...
-       WHERE_SETUP    = 4
+       # argument: menuid. Fnc must return list with menuitems (2-tuple of name, fnc to call)
+       WHERE_MENU = 4
        
        # reason (0: start, 1: end)
        WHERE_AUTOSTART = 5
index 25cad5c4406ee0fe6589c6cdb0f611224fe9b476..048722cff79ac81993d0212e9ec99a9c988b3489 100644 (file)
@@ -575,6 +575,6 @@ def PositionerSetupStart(menuid, **kwargs):
 
 def Plugins(**kwargs):
        if (nimmanager.hasNimType("DVB-S")):
-               return PluginDescriptor(name=_("Positioner setup"), description="Setup your positioner", where = PluginDescriptor.WHERE_SETUP, fnc=PositionerSetupStart)
+               return PluginDescriptor(name=_("Positioner setup"), description="Setup your positioner", where = PluginDescriptor.WHERE_MENU, fnc=PositionerSetupStart)
        else:
                return []
index faa9b05737778320c3d78f3731a14ce33aab7cf9..77c4d0a37010eca931f46cf8ac4d1d6a4b34892c 100644 (file)
@@ -67,6 +67,6 @@ def SecSetupStart(menuid):
 
 def Plugins(**kwargs):
        if (nimmgr.hasNimType("DVB-S")):
-               return PluginDescriptor(name=_("Satellite Equipment Setup"), description="Setup your satellite equipment", where = PluginDescriptor.WHERE_SETUP, fnc=SecSetupStart)
+               return PluginDescriptor(name=_("Satellite Equipment Setup"), description="Setup your satellite equipment", where = PluginDescriptor.WHERE_MENU, fnc=SecSetupStart)
        else:
                return []
index 93a0526a8767a768da7cd7ec641e82c4613d148c..9ad113021640c2158731f5020ba17a6a059524cd 100644 (file)
@@ -278,6 +278,6 @@ def SatfinderStart(menuid, **kwargs):
 
 def Plugins(**kwargs):
        if (nimmanager.hasNimType("DVB-S")):
-               return PluginDescriptor(name=_("Satfinder"), description="Helps setting up your dish", where = PluginDescriptor.WHERE_SETUP, fnc=SatfinderStart)
+               return PluginDescriptor(name=_("Satfinder"), description="Helps setting up your dish", where = PluginDescriptor.WHERE_MENU, fnc=SatfinderStart)
        else:
                return []
index d92211753ce142b8f68ab58cfb4bea226ecb9fa0..ecebe7647e1cd97470ccc26f0089865f65512c15 100755 (executable)
@@ -136,4 +136,4 @@ def SkinSelSetup(menuid, **kwargs):
                return []
 
 def Plugins(**kwargs):
-       return PluginDescriptor(name="Skinselector", description="Select Your Skin", where = PluginDescriptor.WHERE_SETUP, fnc=SkinSelSetup)
+       return PluginDescriptor(name="Skinselector", description="Select Your Skin", where = PluginDescriptor.WHERE_MENU, fnc=SkinSelSetup)