+ cursel = self["list"].l.getCurrentSelection()
+ if cursel:
+ self.goEntry(cursel[0])
+ else:
+ self.cancel()
+
+ # runs a specific entry
+ def goEntry(self, entry):
+ if len(entry) > 2 and isinstance(entry[1], str) and entry[1] == "CALLFUNC":
+ # CALLFUNC wants to have the current selection as argument
+ arg = self["list"].l.getCurrentSelection()[0]
+ entry[2](arg)
+ else:
+ self.close(entry)