X-Git-Url: https://git.cweiske.de/enigma2.git/blobdiff_plain/9b6b96172d1d20d9daf3c11bc5f0222f487d53d7..191cade7c45bee53df2776ff5bb3f26b2cdafc12:/lib/python/Components/config.py diff --git a/lib/python/Components/config.py b/lib/python/Components/config.py index 635eb748..7c7acc34 100644 --- a/lib/python/Components/config.py +++ b/lib/python/Components/config.py @@ -92,10 +92,17 @@ class configSelection: def __call__(self, selected): #needed by configlist self.checkValues() - if isinstance(self.parent.vals[self.parent.value], str): - returnValue = _(self.parent.vals[self.parent.value]) - else: - returnValue = _(self.parent.vals[self.parent.value][1]) + + returnValue = _(self.parent.vals[self.parent.value]) + if not isinstance(returnValue, str): + returnValue = returnValue[1] + + # FIXME: it's not really nice to translate this here. + # however, configSelections are persistent. + + # WORKAROUND: don't translate "" + if returnValue: + returnValue = _(returnValue) return ("text", returnValue)