// try to get the reference from our default mapping
// first try the language and country
String ref = (String)localeToLanguageReference.get(currentLocale.toString());
if (ref != null)
{
return new CompressedResourceReference(DatePickerSettings.class, ref);
}
// now try only the language
ref = (String)localeToLanguageReference.get(currentLocale.getLanguage());
if (ref != null)
{
return new CompressedResourceReference(DatePickerSettings.class, ref);
}
// we didn't find a mapping; just return English
return new CompressedResourceReference(DatePickerSettings.class, "lang/calendar-en.js");
}