small optimizations and cleanups by Moritz Venn
[vuplus_dvbapp] / lib / python / Components / Converter / RdsInfo.py
index 3a7b2be..f3f2b67 100644 (file)
@@ -9,18 +9,12 @@ class RdsInfo(Converter, object):
 
        def __init__(self, type):
                Converter.__init__(self, type)
-               self.type = {
-                               "RadioText": self.RADIO_TEXT_CHANGED,
-                               "RtpText": self.RTP_TEXT_CHANGED,
-                               "RasInteractiveAvailable": self.RASS_INTERACTIVE_AVAILABLE
+               self.type, self.interesting_events = {
+                               "RadioText": (self.RADIO_TEXT_CHANGED, (iPlayableService.evUpdatedRadioText,)),
+                               "RtpText": (self.RTP_TEXT_CHANGED, (iPlayableService.evUpdatedRtpText,)),
+                               "RasInteractiveAvailable": (self.RASS_INTERACTIVE_AVAILABLE, (iPlayableService.evUpdatedRassInteractivePicMask,))
                        }[type]
 
-               self.interesting_events = {
-                               self.RADIO_TEXT_CHANGED: [iPlayableService.evUpdatedRadioText],
-                               self.RTP_TEXT_CHANGED: [iPlayableService.evUpdatedRtpText],
-                               self.RASS_INTERACTIVE_AVAILABLE: [iPlayableService.evUpdatedRassInteractivePicMask]
-                       }[self.type]
-
        @cached
        def getText(self):
                decoder = self.source.decoder