ICU-10968 More efficient implementation for scriptDisplayName(UScriptCode, ...) (C)
X-SVN-Rev: 36379
This commit is contained in:
parent
fb4d6e1222
commit
8c07d13306
@ -728,15 +728,7 @@ LocaleDisplayNamesImpl::scriptDisplayName(const char* script,
|
||||
UnicodeString&
|
||||
LocaleDisplayNamesImpl::scriptDisplayName(UScriptCode scriptCode,
|
||||
UnicodeString& result) const {
|
||||
const char* name = uscript_getName(scriptCode);
|
||||
if (nameLength == UDISPCTX_LENGTH_SHORT) {
|
||||
langData.get("Scripts%short", name, result);
|
||||
if (!result.isBogus()) {
|
||||
return adjustForUsageAndContext(kCapContextUsageScript, result);
|
||||
}
|
||||
}
|
||||
langData.get("Scripts", name, result);
|
||||
return adjustForUsageAndContext(kCapContextUsageScript, result);
|
||||
return scriptDisplayName(uscript_getName(scriptCode), result);
|
||||
}
|
||||
|
||||
UnicodeString&
|
||||
|
Loading…
Reference in New Issue
Block a user