aboutsummaryrefslogtreecommitdiff
path: root/lib/python/Plugins/example.py
diff options
context:
space:
mode:
Diffstat (limited to 'lib/python/Plugins/example.py')
-rw-r--r--lib/python/Plugins/example.py34
1 files changed, 34 insertions, 0 deletions
diff --git a/lib/python/Plugins/example.py b/lib/python/Plugins/example.py
new file mode 100644
index 00000000..86e2cd14
--- /dev/null
+++ b/lib/python/Plugins/example.py
@@ -0,0 +1,34 @@
+from enigma import *
+from Screens.Screen import Screen
+from Components.ActionMap import ActionMap
+from Components.Label import Label
+
+class Example(Screen):
+ skin = """
+ <screen position="100,100" size="200,200" title="Example plugin..." >
+ <widget name="text" position="0,0" size="100,50" font="Arial;23" />
+ </screen>"""
+
+ def __init__(self, session):
+ self.skin = Example.skin
+ Screen.__init__(self, session)
+
+ self["text"] = Label("Small test")
+
+ self["actions"] = ActionMap(["WizardActions"],
+ {
+ "ok": self.ok
+ }, -1)
+
+ def ok(self):
+ self.close()
+
+def main(session):
+ session.open(Example)
+
+
+def getPicturePath():
+ return "/usr/share/enigma2/record.png"
+
+def getPluginName():
+ return "Fancy example-plugin" \ No newline at end of file