Beispiel #1
0
 def determine_language_installer(self, gog_installers, default_language):
     """Return locale language string if available in gog_installers"""
     language = i18n.get_lang()
     gog_installers = [installer for installer in gog_installers if installer["language"] == language]
     if not gog_installers:
         language = default_language
     return language
Beispiel #2
0
    def __init__(self):
        super().__init__()
        self.selected_extras = None

        gog_locales = {
            "en": "en-US",
            "de": "de-DE",
            "fr": "fr-FR",
            "pl": "pl-PL",
            "ru": "ru-RU",
            "zh": "zh-Hans",
        }
        self.locale = gog_locales.get(i18n.get_lang(), "en-US")