Thanks a lot for your suggestion !
Unfortunately, it does not work.
The language switcher gets displayed at the first function call.
$switcher = pll_the_languages(array('show_flags'=>1,'show_names'=>1,'force_home'=>0, 'hide_if_no_translation'=>1, 'hide_current'=>1));
Also, $switcher seems to be false in all cases.