I have a problem with internationalization at the click of a button

hi !
i try to change the language for my site at clicking of a button, by using :
bt_english.addClickListener(new Button.ClickListener() {
@Override
public void buttonClick(ClickEvent event) {
Locale englais=new Locale(“en”,“EN”);
Locale.setDefault(englais);

				}
			});

it work out the button but here it doesn’t work.
thank you.

Not sure how you’re using the Locale in your internationalization but if you receive it using UI.getCurrent().getLocale(); you now have to set it like this:
UI.getCurrent().setLocale(englais);