1 Reply Latest reply on Jan 28, 2009 7:20 PM by everynerd

    Help with localization across multiple projects

      Hi everyone

      I'm having some difficulties getting localization to work with a library project as well as an application project.

      Our projects are like so:
      -library project
      -- locale
      --- en_US -> resources.properties

      - application project
      -- locale
      --- en_US -> resources.properties

      The problem I'm having is that I can't seem to get the application to use both of these english resources. Ideally, as with the rest of the application, I would like to inherit from the library project and append necessary application-specific language in the properties file.

      I've tried many different strategies and combinations of allow-source-path-overlap and so on, even rename resources.properties in the application to [whatever].properties and referencing the bundle in Flex doesn't register.

      Is there a solution to this? If there's any way that someone knows how to use multiple same-language locales across multiple projects I would love to know how.

        • 1. Re: Help with localization across multiple projects
          everynerd Level 1
          Today I managed to figure this out.

          In the library project, I changed the name of resources.properties to [libraryname].properties, the Flex Builder compile option -allow-source-path-overlap is set, and the locale/{locale} directory is added as a source path.

          In the application project I've changed the resources.properties file to [appname].properties, added same compile option, as well as -locale=en_US, and added its locale directory as a source path as well as the library's locale, The library's locale, because of the localeChain in this case being en_US, the Flex Navigator will show the folder as [source path] en_US.

          In the application.mxml file, all I had to do was add:

          And where necessary, refer to the bundles by those names.