fix no more working displaying of used tuner for foreground service
[enigma2.git] / lib / python / Screens / InfoBarGenerics.py
index 9b3c5cf4771a420847312dd868a1f5b725e27160..b16594f430485908f323732b6e36f8ae3d37617a 100644 (file)
@@ -227,7 +227,7 @@ class InfoBarNumberZap:
                        bouquetlist = serviceHandler.list(bouquet)
                        if not bouquetlist is None:
                                while number:
-                                       bouquet = self.servicelist.appendDVBTypes(bouquetlist.getNext())
+                                       bouquet = bouquetlist.getNext()
                                        if not bouquet.valid(): #check end of list
                                                break
                                        if bouquet.flags & eServiceReference.isDirectory:
@@ -1336,9 +1336,21 @@ class InfoBarInstantRecord:
                        return
 
                if self.isInstantRecordRunning():
-                       self.session.openWithCallback(self.recordQuestionCallback, ChoiceBox, title=_("A recording is currently running.\nWhat do you want to do?"), list=[(_("stop recording"), "stop"), (_("change recording (duration)"), "changeduration"), (_("add recording (indefinitely)"), "indefinitely"), (_("add recording (stop after current event)"), "event"), (_("add recording (enter recording duration)"), "manualduration"), (_("do nothing"), "no")])
+                       self.session.openWithCallback(self.recordQuestionCallback, ChoiceBox, \
+                               title=_("A recording is currently running.\nWhat do you want to do?"), \
+                               list=[(_("stop recording"), "stop"), \
+                               (_("change recording (duration)"), "changeduration"), \
+                               (_("add recording (indefinitely)"), "indefinitely"), \
+                               (_("add recording (stop after current event)"), "event"), \
+                               (_("add recording (enter recording duration)"), "manualduration"), \
+                               (_("do nothing"), "no")])
                else:
-                       self.session.openWithCallback(self.recordQuestionCallback, ChoiceBox, title=_("Start recording?"), list=[(_("add recording (indefinitely)"), "indefinitely"), (_("add recording (stop after current event)"), "event"), (_("add recording (enter recording duration)"), "manualduration"),(_("don't record"), "no")])
+                       self.session.openWithCallback(self.recordQuestionCallback, ChoiceBox, \
+                               title=_("Start recording?"), \
+                               list=[(_("add recording (indefinitely)"), "indefinitely"), \
+                               (_("add recording (stop after current event)"), "event"), \
+                               (_("add recording (enter recording duration)"), "manualduration"), \
+                               (_("don't record"), "no")])
 
 from Tools.ISO639 import LanguageCodes
 
@@ -1575,7 +1587,7 @@ class InfoBarAdditionalInfo:
 
        def gotServiceEvent(self, ev):
                service = self.session.nav.getCurrentService()
-               if ev == iPlayableService.evStart:
+               if ev == iPlayableService.evNewProgramInfo:
                        self.checkTunerState(service)
 
 class InfoBarNotifications:
@@ -1896,10 +1908,7 @@ class InfoBarServiceErrorPopupSupport:
                        eDVBServicePMTHandler.eventEOF: None
                }
 
-               if error not in errors:
-                       error = None
-
-               error = error is not None and errors[error]
+               error = errors.get(error) #this returns None when the key not exist in the dict
 
                if error is not None:
                        Notifications.AddPopup(text = error, type = MessageBox.TYPE_ERROR, timeout = 5, id = "ZapError")