Hi Guys,
I am newbie and just starting with developing plugins for engima2.
I am trying to write a plugin that would automatically show some dialog box after the dreambox is booted.
Below is part of my code, it works ok when started manually from plugin menu, but fails to start automatically after boot.
Would appreciate any help.
Thanks
Code
def autoStart(reason, **kwargs):
global session
if reason == 0 and kwargs.has_key("session"):
session = kwargs["session"]
session.open(SomeScreen)
###########################################################################
def Plugins(**kwargs):
return [PluginDescriptor(
name="Hello",
description="some plugin",
where = PluginDescriptor.WHERE_PLUGINMENU,
icon="../me_tut.png",
fnc=main),
PluginDescriptor(
where = [
PluginDescriptor.WHERE_SESSIONSTART,
PluginDescriptor.WHERE_AUTOSTART
],
fnc=autoStart)
]
Alles anzeigen