git.cweiske.de
/
enigma2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
add new box depending rc visualization
[enigma2.git]
/
lib
/
python
/
Screens
/
ChoiceBox.py
diff --git
a/lib/python/Screens/ChoiceBox.py
b/lib/python/Screens/ChoiceBox.py
index 37729887c744678514c0cb1cb5f2661bd8784993..0436f66d0152993fff3076e0614b07bf27f86f8b 100644
(file)
--- a/
lib/python/Screens/ChoiceBox.py
+++ b/
lib/python/Screens/ChoiceBox.py
@@
-1,8
+1,6
@@
from Screens.Screen import Screen
from Screens.Screen import Screen
-from Screens.MessageBox import MessageBox
from Components.ActionMap import NumberActionMap
from Components.Label import Label
from Components.ActionMap import NumberActionMap
from Components.Label import Label
-from Components.MenuList import MenuList
from Components.ChoiceList import ChoiceEntryComponent, ChoiceList
class ChoiceBox(Screen):
from Components.ChoiceList import ChoiceEntryComponent, ChoiceList
class ChoiceBox(Screen):
@@
-74,7
+72,11
@@
class ChoiceBox(Screen):
# runs the current selected entry
def go(self):
# runs the current selected entry
def go(self):
- self.goEntry(self["list"].l.getCurrentSelection()[0])
+ cursel = self["list"].l.getCurrentSelection()
+ if cursel:
+ self.goEntry(cursel[0])
+ else:
+ self.cancel()
# runs a specific entry
def goEntry(self, entry):
# runs a specific entry
def goEntry(self, entry):