1 from enigma import loadPNG
3 class PluginDescriptor:
4 """An object to describe a plugin."""
6 # where to list the plugin. Note that there are different call arguments,
7 # so you might not be able to combine them.
9 # supported arguments are:
18 # argument: session, serviceref (currently selected)
23 # reason (0: start, 1: end)
26 # start as wizard. In that case, fnc must be a screen class!
29 def __init__(self, name = "Plugin", where = [ ], description = "", icon = None, fnc = None):
31 if type(where) is list:
34 self.where = [ where ]
35 self.description = description
37 if type(icon) is str or icon is None:
45 def updateIcon(self, path):
46 if type(self.iconstr) is str:
47 self.icon = loadPNG(path + self.iconstr)
51 def __eq__(self, other):
52 return self.__call__ == other.__call__