From 8a9355a98ece3d7fc9d022e759d05378060c86e2 Mon Sep 17 00:00:00 2001 From: Adam Lesinski Date: Tue, 10 Mar 2015 16:55:43 -0700 Subject: Output modified bcp47 tag in ResTable_config::toString() We expect to be able to parse the output of ResTable_config::toString(), so it should use modified bcp47 (b+en+Latn+US). Change-Id: I597a1779a1fa5cff171c473e6a0368d93b9c7722 --- include/androidfw/ResourceTypes.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'include') diff --git a/include/androidfw/ResourceTypes.h b/include/androidfw/ResourceTypes.h index 86732196518c..65160d5bf858 100644 --- a/include/androidfw/ResourceTypes.h +++ b/include/androidfw/ResourceTypes.h @@ -1195,6 +1195,12 @@ struct ResTable_config // Example: en-US, en-Latn-US, en-POSIX. void getBcp47Locale(char* out) const; + // Append to str the resource-qualifer string representation of the + // locale component of this Config. If the locale is only country + // and language, it will look like en-rUS. If it has scripts and + // variants, it will be a modified bcp47 tag: b+en+Latn+US. + void appendDirLocale(String8& str) const; + // Sets the values of language, region, script and variant to the // well formed BCP-47 locale contained in |in|. The input locale is // assumed to be valid and no validation is performed. -- cgit v1.2.3-59-g8ed1b