Commits

Guido Draheim  committed caef83c

initialize adapters

  • Participants
  • Parent commits 7aa2c1b

Comments (0)

Files changed (1)

File src/dvbcronrecording/computer.py

 onlydate_rank = 0.5 # +1
 rankup_channels = [ "3sat", "arte" ]
 rankup_plus = 0.3
+default_adapter = "0"
 
 def intnull(value, default = None):
     if value is None: return default
         self.newtimeMMM = 0
         self.endtimeMMM = 0
         self.extratimeM = 0
+        self.adapters = [ default_adapter ]
         self.set(orig)
     def set(self, orig):
         if orig is not None:
     def adapters(self, channelname):
         if channelname in self._adapters:
             return self._adapters[channelname]
-        return ["0"]
+        return [ default_adapter ]
     def set_adapters_from_channels_list(self, channelslist):
         for entry in channelslist:
             channelname = entry.channelname
                         elem = RecorderTime(item)
                         elem.datetimeX = date + datetime.timedelta(minutes = newtimeMMM)
                         elem.datetimeY = date + datetime.timedelta(minutes = endtimeMMM)
+                        elem.adapters = self.adapters(item.channelname)
                         # elem.message += " (([%s .. %s] from %s..%s))" % (elem.datetimeX, elem.datetimeY, newtimeMMM, endtimeMMM)
                         yield elem
                 except: