I creadet a class that has more ResourceBundles in it. My app is multilanguage so I will need many “.properties” files.
here is a sample code
[ResourceBundle("LocalizedStrings_en_US")]
[ResourceBundle("LocalizedStrings_fr_FR")]
...
public class LocaleLoader
{
...
}
My question is if I add many ResourceBunlde lines in this class, will the file size of the main swf increase drastically or not?
Should use separata class files to load separate ResourceBundles for each language?
The
[ResourceBundle]annotation itself won’t have any effect on the file size. It’s the-localecompile option of the mxmlc that matters.-locale=en_USmeans to embed only the US-locale in the SWF-locale=en_US, ja_JPmeans to embed both the US-locale and the Japan-localeIf you don’t embed the Japan-locale you can load it at runtime with
resourceManager.loadResourceModule(...).To address completely the topic of Flex Localization Support please refer to the Slides & Samples in the Flex Localization Support article I wrote in the Obecto Training Portal.