New translation system, that generates screens for updating translations through the web, within the configuration.

This commit is contained in:
Gaetan Delannay 2011-01-14 09:06:25 +01:00
parent f3604624de
commit ead9f7c2de
22 changed files with 525 additions and 278 deletions

View file

@ -197,6 +197,15 @@ class Languages:
'''Is p_code a valid 2-digits language/country code?'''
return code in self.languageCodes
def get(self, code):
'''Returns information about the language whose code is p_code.'''
try:
iCode = self.languageCodes.index(code)
return self.languageCodes[iCode], self.languageNames[iCode], \
self.nativeNames[iCode]
except ValueError:
return None, None, None
def __repr__(self):
i = -1
res = ''