@classmethod
def showSelector(class_, config, layout):
    """We must show the language selector if the p_config requires it and if
           there is more than 2 supported languages. Moreover, on some layouts,
           switching the language is not allowed."""
    if not config.languageSelector or config.forcedLanguage:
        return
    if len(config.languages) < 2:
        return
    return layout not in ('edit', 'search')
