1 from Screen import Screen
2 from Components.ActionMap import ActionMap
3 from Components.Sources.StaticText import StaticText
4 from Components.Harddisk import harddiskmanager
5 from Components.NimManager import nimmanager
6 from Components.About import about
8 from Tools.DreamboxHardware import getFPVersion
11 def __init__(self, session):
12 Screen.__init__(self, session)
14 self["EnigmaVersion"] = StaticText("Enigma: " + about.getEnigmaVersionString())
15 self["ImageVersion"] = StaticText("Image: " + about.getImageVersionString())
17 self["TunerHeader"] = StaticText(_("Detected NIMs:"))
19 fp_version = getFPVersion()
20 if fp_version is None:
23 fp_version = _("Frontprocessor version: %d") % fp_version
25 self["FPVersion"] = StaticText(fp_version)
27 nims = nimmanager.nimList()
28 for count in (0, 1, 2, 3):
30 self["Tuner" + str(count)] = StaticText(nims[count])
32 self["Tuner" + str(count)] = StaticText("")
34 self["HDDHeader"] = StaticText(_("Detected HDD:"))
35 hddlist = harddiskmanager.HDDList()
36 hdd = hddlist and hddlist[0][1] or None
37 if hdd is not None and hdd.model() != "":
38 self["hddA"] = StaticText(_("%s\n(%s, %d MB free)") % (hdd.model(), hdd.capacity(),hdd.free()))
40 self["hddA"] = StaticText(_("none"))
42 self["actions"] = ActionMap(["SetupActions", "ColorActions"],
46 "green": self.showTranslationInfo
49 def showTranslationInfo(self):
50 self.session.open(TranslationInfo)
52 class TranslationInfo(Screen):
53 def __init__(self, session):
54 Screen.__init__(self, session)
55 # don't remove the string out of the _(), or it can't be "translated" anymore.
57 # TRANSLATORS: Add here whatever should be shown in the "translator" about screen, up to 6 lines (use \n for newline)
58 info = _("TRANSLATOR_INFO")
60 if info == "TRANSLATOR_INFO":
63 infolines = _("").split("\n")
73 self["TranslationInfo"] = StaticText(info)
75 translator_name = infomap.get("Language-Team", "none")
76 if translator_name == "none":
77 translator_name = infomap.get("Last-Translator", "")
79 self["TranslatorName"] = StaticText(translator_name)
81 self["actions"] = ActionMap(["SetupActions"],