ICU-1268 use ures_openDirect() for non-locale resource bundles

X-SVN-Rev: 6177
This commit is contained in:
Markus Scherer 2001-10-11 00:50:26 +00:00
parent 5c7b7284f0
commit 74cfc16466
3 changed files with 3 additions and 9 deletions

View File

@ -1056,7 +1056,7 @@ static void _lazyEvaluate_installedLocales()
int32_t localeCount;
ures_setIsStackObject(&installed, TRUE);
index = ures_open(NULL, _kIndexLocaleName, &status);
index = ures_openDirect(NULL, _kIndexLocaleName, &status);
ures_getByKey(index, _kIndexTag, &installed, &status);
if(U_SUCCESS(status)) {

View File

@ -1446,10 +1446,7 @@ void Transliterator::initializeRegistry(void) {
Locale indexLoc("translit_index");
UResourceBundle *bundle, *transIDs, *colBund;
// TODO call internal ures_openXYZ() that guarantees to not canonicalize
// (uloc_getName()) the ch resource bundle name, and that also
// will not try fallbacks
bundle = ures_open(0, "translit_index", &status);
bundle = ures_openDirect(0, "translit_index", &status);
transIDs = ures_getByKey(bundle, RB_RULE_BASED_IDS, 0, &status);
int32_t row, maxRows;

View File

@ -929,10 +929,7 @@ Transliterator* TransliteratorRegistry::instantiateEntry(const UnicodeString& ID
// just using the locale mechanism to map through to a file
// name; this in no way represents an actual locale.
CharString ch(entry->stringArg);
// TODO call internal ures_openXYZ() that guarantees to not canonicalize
// (uloc_getName()) the ch resource bundle name, and that also
// will not try fallbacks
UResourceBundle *bundle = ures_open(0, ch, &status);
UResourceBundle *bundle = ures_openDirect(0, ch, &status);
UnicodeString rules = ures_getUnicodeStringByKey(bundle, RB_RULE, &status);
ures_close(bundle);