X-Git-Url: https://git.saurik.com/android/aapt.git/blobdiff_plain/a189615a5671748c348da8ab79042e9e2746eb5e..a534180cd5d99f3e0ce8bb19c14f57074ffb102a:/ResourceTable.cpp diff --git a/ResourceTable.cpp b/ResourceTable.cpp index 877763d..6f71a1e 100644 --- a/ResourceTable.cpp +++ b/ResourceTable.cpp @@ -644,6 +644,7 @@ status_t compileResourceFile(Bundle* bundle, const String16 bool16("bool"); const String16 integer16("integer"); const String16 dimen16("dimen"); + const String16 fraction16("fraction"); const String16 style16("style"); const String16 plurals16("plurals"); const String16 array16("array"); @@ -1022,6 +1023,10 @@ status_t compileResourceFile(Bundle* bundle, curTag = &dimen16; curType = dimen16; curFormat = ResTable_map::TYPE_REFERENCE|ResTable_map::TYPE_DIMENSION; + } else if (strcmp16(block.getElementName(&len), fraction16.string()) == 0) { + curTag = &fraction16; + curType = fraction16; + curFormat = ResTable_map::TYPE_REFERENCE|ResTable_map::TYPE_FRACTION; } else if (strcmp16(block.getElementName(&len), bag16.string()) == 0) { curTag = &bag16; curIsBag = true; @@ -2165,15 +2170,14 @@ ResourceTable::validateLocalizations(void) // consider that string to have fulfilled the localization requirement. String8 region(config.string(), 2); if (configSet.find(region) == configSet.end()) { - // TODO: force an error if there is no default to fall back to if (configSet.count(defaultLocale) == 0) { - fprintf(stdout, "aapt: warning: " + fprintf(stdout, "aapt: error: " "*** string '%s' has no default or required localization " "for '%s' in %s\n", String8(nameIter->first).string(), config.string(), mBundle->getResourceSourceDirs()[0]); - //err = UNKNOWN_ERROR; + err = UNKNOWN_ERROR; } } }