aboutsummaryrefslogtreecommitdiff
path: root/lib/python
diff options
context:
space:
mode:
Diffstat (limited to 'lib/python')
-rw-r--r--lib/python/Plugins/DemoPlugins/TestPlugin/plugin.py2
-rw-r--r--lib/python/Screens/ChoiceBox.py5
2 files changed, 4 insertions, 3 deletions
diff --git a/lib/python/Plugins/DemoPlugins/TestPlugin/plugin.py b/lib/python/Plugins/DemoPlugins/TestPlugin/plugin.py
index d4d24f32..c4e28fea 100644
--- a/lib/python/Plugins/DemoPlugins/TestPlugin/plugin.py
+++ b/lib/python/Plugins/DemoPlugins/TestPlugin/plugin.py
@@ -69,7 +69,7 @@ class Test(Screen):
self["text"].number(number)
def main(session):
- session.openWithCallback(test, ChoiceBox, title="Hallo", list=[(_("yes"), "yes"), (_("no"), "no")])
+ session.openWithCallback(test, ChoiceBox, title="Delete everything on this Dreambox?", list=[(_("yes"), "yes"), (_("no"), "no"), (_("perhaps"), "perhaps"), (_("ask me tomorrow"), "ask me tomorrow"), (_("leave me alone with this s§&$!"), "yes")])
def test(returnValue):
print "You entered", returnValue
diff --git a/lib/python/Screens/ChoiceBox.py b/lib/python/Screens/ChoiceBox.py
index 533e78d0..cc6afb1c 100644
--- a/lib/python/Screens/ChoiceBox.py
+++ b/lib/python/Screens/ChoiceBox.py
@@ -9,11 +9,12 @@ from Components.GUIComponent import *
import os
class ChoiceBox(Screen):
- def __init__(self, session, title = "", **kwargs):
+ def __init__(self, session, title = "", list = []):
Screen.__init__(self, session)
self["text"] = Label(title)
- self["list"] = MenuList(**kwargs)
+ self.list = list
+ self["list"] = MenuList(list)
self["actions"] = NumberActionMap(["WizardActions", "InputActions"],
{