- subtitleString = self.service.info().getInfoString(iServiceInformation.sUser+7)
- print "SubtitleInfoAvail "+subtitleString
- self["subtitleLabel"].setText(subtitleString)
- if not self.in_menu:
- self.doShow()
+ info = self.getServiceInterface("info")
+ subtitleTuple = info and info.getInfoObject(iServiceInformation.sUser+7)
+ print "SubtitleInfoAvail ", repr(subtitleTuple)
+ if subtitleTuple:
+ subtitleString = ""
+ if subtitleTuple[0] is not 0:
+ subtitleString = "%d: %s" % (subtitleTuple[0],subtitleTuple[1])
+ self["subtitleLabel"].setText(subtitleString)
+ if subtitleTuple != self.last_subtitleTuple and not self.in_menu:
+ self.doShow()
+ self.last_subtitleTuple = subtitleTuple
+
+ def __osdAngleInfoAvail(self):
+ info = self.getServiceInterface("info")
+ angleTuple = info and info.getInfoObject(iServiceInformation.sUser+8)
+ print "AngleInfoAvail ", repr(angleTuple)
+ if angleTuple:
+ angleString = ""
+ if angleTuple[1] > 1:
+ angleString = "%d / %d" % (angleTuple[0],angleTuple[1])
+ self["anglePix"].show()
+ else:
+ self["anglePix"].hide()
+ self["angleLabel"].setText(angleString)
+ if angleTuple != self.last_angleTuple and not self.in_menu:
+ self.doShow()
+ self.last_angleTuple = angleTuple