I have an Vaadin portlet wich supports "Multilanguage" that means if an user selects for eg DE in the liferay portal he will get the German translation of some portlets and if he select another language the portlet will be translated to the selected language. there is a problem, the user can translate the portlet only one time , if he selects another language, the portlet keeps the translated strings of the previous language , and the portlet keeps the old language till the portlets init method is reloaded. is there a way to dynamicaly change the language of the portlets components without losing the curret users state(modifications) ?
There is a pattern for Vaadin component translation that may apply here:
For storing multiple translation keys into data-property (for the caption and description separately) create your own class or use Map.
Note also that if you have data coming from the database, this pattern does not help and you have to solve that some other way.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.