public virtual string GetDisplayName(string id, UCultureInfo locale) { // assume if the user called this on us, we must have handled some fallback of this id // if (isSupportedID(id)) { if (locale == null) { return(id); } UCultureInfo loc = new UCultureInfo(id); return(loc.GetDisplayName(locale)); // } // return null; }
internal string GetDisplayName(UCultureInfo displayLocale) { string name = null; if (displayNames != null) { name = displayNames.TryGetValue(displayLocale, out object val) ? (string)val : null; } if (name == null) { name = locale.GetDisplayName(displayLocale); } return(name); }