Home
last modified time | relevance | path

Searched refs:locale (Results 1 – 25 of 170) sorted by relevance

1234567

/frameworks/support/v4/java/android/support/v4/text/
DICUCompat.java24 public String getScript(String locale); in getScript() argument
25 public String addLikelySubtags(String locale); in addLikelySubtags() argument
30 public String getScript(String locale) { in getScript() argument
35 public String addLikelySubtags(String locale) { in addLikelySubtags() argument
36 return locale; in addLikelySubtags()
42 public String getScript(String locale) { in getScript() argument
43 return ICUCompatIcs.getScript(locale); in getScript()
47 public String addLikelySubtags(String locale) { in addLikelySubtags() argument
48 return ICUCompatIcs.addLikelySubtags(locale); in addLikelySubtags()
69 public static String getScript(String locale) { in getScript() argument
[all …]
DTextUtilsCompat.java75 public static int getLayoutDirectionFromLocale(@Nullable Locale locale) { in getLayoutDirectionFromLocale() argument
76 if (locale != null && !locale.equals(ROOT)) { in getLayoutDirectionFromLocale()
78 ICUCompat.addLikelySubtags(locale.toString())); in getLayoutDirectionFromLocale()
79 if (scriptSubtag == null) return getLayoutDirectionFromFirstChar(locale); in getLayoutDirectionFromLocale()
102 private static int getLayoutDirectionFromFirstChar(Locale locale) { in getLayoutDirectionFromFirstChar() argument
103 switch(Character.getDirectionality(locale.getDisplayName(locale).charAt(0))) { in getLayoutDirectionFromFirstChar()
/frameworks/base/core/java/android/view/
DAccessibilityIterators.java75 public static CharacterTextSegmentIterator getInstance(Locale locale) { in getInstance() argument
77 sInstance = new CharacterTextSegmentIterator(locale); in getInstance()
82 private CharacterTextSegmentIterator(Locale locale) { in CharacterTextSegmentIterator() argument
83 mLocale = locale; in CharacterTextSegmentIterator()
84 onLocaleChanged(locale); in CharacterTextSegmentIterator()
148 Locale locale = newConfig.locale; in onConfigurationChanged() local
149 if (!mLocale.equals(locale)) { in onConfigurationChanged()
150 mLocale = locale; in onConfigurationChanged()
151 onLocaleChanged(locale); in onConfigurationChanged()
160 protected void onLocaleChanged(Locale locale) { in onLocaleChanged() argument
[all …]
/frameworks/base/tools/layoutlib/bridge/src/libcore/icu/
DICU_Delegate.java106 /*package*/ static String getCurrencyCode(String locale) { in getCurrencyCode() argument
111 /*package*/ static String getCurrencyDisplayName(String locale, String currencyCode) { in getCurrencyDisplayName() argument
126 /*package*/ static String getCurrencySymbol(String locale, String currencyCode) { in getCurrencySymbol() argument
131 /*package*/ static String getDisplayCountryNative(String countryCode, String locale) { in getDisplayCountryNative() argument
136 /*package*/ static String getDisplayLanguageNative(String languageCode, String locale) { in getDisplayLanguageNative() argument
141 /*package*/ static String getDisplayVariantNative(String variantCode, String locale) { in getDisplayVariantNative() argument
146 /*package*/ static String getDisplayScriptNative(String variantCode, String locale) { in getDisplayScriptNative() argument
151 /*package*/ static String getISO3Country(String locale) { in getISO3Country() argument
156 /*package*/ static String getISO3Language(String locale) { in getISO3Language() argument
161 /*package*/ static String addLikelySubtags(String locale) { in addLikelySubtags() argument
[all …]
/frameworks/base/core/java/com/android/internal/app/
DLocalePicker.java51 public void onLocaleSelected(Locale locale); in onLocaleSelected() argument
60 Locale locale; field in LocalePicker.LocaleInfo
62 public LocaleInfo(String label, Locale locale) { in LocaleInfo() argument
64 this.locale = locale; in LocaleInfo()
72 return locale; in getLocale()
104 for (String locale : localeList) { in getAllAssetLocales()
105 final Locale l = Locale.forLanguageTag(locale.replace('_', '-')); in getAllAssetLocales()
122 if (previous.locale.getLanguage().equals(l.getLanguage()) && in getAllAssetLocales()
123 !previous.locale.getLanguage().equals("zz")) { in getAllAssetLocales()
126 … getDisplayName(previous.locale, specialLocaleCodes, specialLocaleNames)); in getAllAssetLocales()
[all …]
/frameworks/base/core/java/android/content/res/
DConfiguration.java82 public Locale locale; field in Configuration
626 if (o.locale != null) { in setTo()
627 locale = (Locale) o.locale.clone(); in setTo()
666 if (locale != null) { in toString()
668 sb.append(locale); in toString()
793 locale = null; in setToDefaults()
838 if (delta.locale != null in updateFrom()
839 && (locale == null || !locale.equals(delta.locale))) { in updateFrom()
841 locale = delta.locale != null in updateFrom()
842 ? (Locale) delta.locale.clone() : null; in updateFrom()
[all …]
/frameworks/base/core/java/android/view/textservice/
DTextServicesManager.java95 private static String parseLanguageFromLocaleString(String locale) { in parseLanguageFromLocaleString() argument
96 final int idx = locale.indexOf('_'); in parseLanguageFromLocaleString()
98 return locale; in parseLanguageFromLocaleString()
100 return locale.substring(0, idx); in parseLanguageFromLocaleString()
118 public SpellCheckerSession newSpellCheckerSession(Bundle bundle, Locale locale, in newSpellCheckerSession() argument
123 if (!referToSpellCheckerLanguageSettings && locale == null) { in newSpellCheckerSession()
147 if (locale != null) { in newSpellCheckerSession()
150 if (subtypeLanguage.length() < 2 || !locale.getLanguage().equals(subtypeLanguage)) { in newSpellCheckerSession()
155 final String localeStr = locale.toString(); in newSpellCheckerSession()
164 locale.getLanguage().equals(tempSubtypeLanguage)) { in newSpellCheckerSession()
DSpellCheckerSubtype.java54 public SpellCheckerSubtype(int nameId, String locale, String extraValue) { in SpellCheckerSubtype() argument
56 mSubtypeLocale = locale != null ? locale : ""; in SpellCheckerSubtype()
180 final Locale locale = constructLocaleFromString(mSubtypeLocale); in getDisplayName() local
181 final String localeStr = locale != null ? locale.getDisplayName() : mSubtypeLocale; in getDisplayName()
219 private static int hashCodeInternal(String locale, String extraValue) { in hashCodeInternal() argument
220 return Arrays.hashCode(new Object[] {locale, extraValue}); in hashCodeInternal()
/frameworks/base/core/java/android/provider/
DUserDictionary.java136 final Locale locale; in addWord() local
139 locale = Locale.getDefault(); in addWord()
141 locale = null; in addWord()
144 addWord(context, word, frequency, null, locale); in addWord()
159 int frequency, String shortcut, Locale locale) { in addWord() argument
174 values.put(LOCALE, null == locale ? null : locale.toString()); in addWord()
DSearchIndexableData.java42 public Locale locale; field in SearchIndexableData
124 locale = Locale.getDefault(); in SearchIndexableData()
145 sb.append(locale); in toString()
/frameworks/base/core/java/com/android/internal/textservice/
DITextServicesManager.aidl32 SpellCheckerInfo getCurrentSpellChecker(String locale); in getCurrentSpellChecker() argument
34 String locale, boolean allowImplicitlySelectedSubtype); in getCurrentSpellCheckerSubtype() argument
35 oneway void getSpellCheckerService(String sciId, in String locale, in getSpellCheckerService() argument
39 oneway void setCurrentSpellChecker(String locale, String sciId); in setCurrentSpellChecker() argument
40 oneway void setCurrentSpellCheckerSubtype(String locale, int hashCode); in setCurrentSpellCheckerSubtype() argument
/frameworks/support/v4/ics/android/support/v4/text/
DICUCompatIcs.java46 public static String getScript(String locale) { in getScript() argument
49 final Object[] args = new Object[] { locale }; in getScript()
63 public static String addLikelySubtags(String locale) { in addLikelySubtags() argument
66 final Object[] args = new Object[] { locale }; in addLikelySubtags()
77 return locale; in addLikelySubtags()
/frameworks/base/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/
DAndroidLocale.java33 public static String toLanguageTag(Locale locale) { in toLanguageTag() argument
34 return ULocale.forLocale(locale).toLanguageTag(); in toLanguageTag()
56 public static String getScript(Locale locale) { in getScript() argument
57 return ULocale.forLocale(locale).getScript(); in getScript()
/frameworks/base/core/java/android/speech/tts/
DTextToSpeechService.java255 private int getExpectedLanguageAvailableStatus(Locale locale) { in getExpectedLanguageAvailableStatus() argument
257 if (locale.getVariant().isEmpty()) { in getExpectedLanguageAvailableStatus()
258 if (locale.getCountry().isEmpty()) { in getExpectedLanguageAvailableStatus()
284 for (Locale locale : Locale.getAvailableLocales()) { in onGetVoices()
285 int expectedStatus = getExpectedLanguageAvailableStatus(locale); in onGetVoices()
287 int localeStatus = onIsLanguageAvailable(locale.getISO3Language(), in onGetVoices()
288 locale.getISO3Country(), locale.getVariant()); in onGetVoices()
296 Set<String> features = onGetFeaturesForLanguage(locale.getISO3Language(), in onGetVoices()
297 locale.getISO3Country(), locale.getVariant()); in onGetVoices()
298 voices.add(new Voice(locale.toLanguageTag(), locale, Voice.QUALITY_NORMAL, in onGetVoices()
[all …]
/frameworks/base/core/java/android/view/inputmethod/
DInputMethodSubtype.java197 private static InputMethodSubtypeBuilder getBuilder(int nameId, int iconId, String locale, in getBuilder() argument
203 builder.mSubtypeLocale = locale; in getBuilder()
220 public InputMethodSubtype(int nameId, int iconId, String locale, String mode, String extraValue, in InputMethodSubtype() argument
222 this(nameId, iconId, locale, mode, extraValue, isAuxiliary, in InputMethodSubtype()
257 public InputMethodSubtype(int nameId, int iconId, String locale, String mode, String extraValue, in InputMethodSubtype() argument
259 this(getBuilder(nameId, iconId, locale, mode, extraValue, isAuxiliary, in InputMethodSubtype()
382 final Locale locale = constructLocaleFromString(mSubtypeLocale); in getDisplayName() local
383 final String localeStr = locale != null ? locale.getDisplayName() : mSubtypeLocale; in getDisplayName()
522 private static int hashCodeInternal(String locale, String mode, String extraValue, in hashCodeInternal() argument
529 return Arrays.hashCode(new Object[] {locale, mode, extraValue, isAuxiliary, in hashCodeInternal()
[all …]
/frameworks/base/core/java/android/text/style/
DLocaleSpan.java37 public LocaleSpan(Locale locale) { in LocaleSpan() argument
38 mLocale = locale; in LocaleSpan()
81 private static void apply(Paint paint, Locale locale) { in apply() argument
82 paint.setTextLocale(locale); in apply()
DSuggestionSpan.java115 public SuggestionSpan(Locale locale, String[] suggestions, int flags) { in SuggestionSpan() argument
116 this(null, locale, suggestions, flags, null); in SuggestionSpan()
128 public SuggestionSpan(Context context, Locale locale, String[] suggestions, int flags, in SuggestionSpan() argument
133 if (locale != null) { in SuggestionSpan()
134 mLocaleString = locale.toString(); in SuggestionSpan()
136 mLocaleString = context.getResources().getConfiguration().locale.toString(); in SuggestionSpan()
283 private static int hashCodeInternal(String[] suggestions, String locale, in hashCodeInternal() argument
286 locale, notificationTargetClassName}); in hashCodeInternal()
/frameworks/base/core/java/android/webkit/
DDateSorter.java68 Locale locale = resources.getConfiguration().locale; in DateSorter() local
69 if (locale == null) { in DateSorter()
70 locale = Locale.getDefault(); in DateSorter()
72 LocaleData localeData = LocaleData.get(locale); in DateSorter()
/frameworks/base/core/java/android/database/sqlite/
DSQLiteDatabaseConfiguration.java77 public Locale locale; field in SQLiteDatabaseConfiguration
110 locale = Locale.getDefault(); in SQLiteDatabaseConfiguration()
145 locale = other.locale; in updateParametersFrom()
/frameworks/base/media/java/android/media/
DSubtitleController.java82 public void onLocaleChanged(Locale locale) {
215 Locale locale = selectedLocale; in getDefaultTrack() local
216 if (locale == null) { in getDefaultTrack()
217 locale = Locale.getDefault(); in getDefaultTrack()
233 (locale == null || in getDefaultTrack()
234 locale.getLanguage().equals("") || in getDefaultTrack()
235 locale.getISO3Language().equals(language) || in getDefaultTrack()
236 locale.getLanguage().equals(language)); in getDefaultTrack()
/frameworks/base/tools/split-select/
DRuleGenerator.cpp102 if (group[index].config.locale != 0) { in generate()
103 sp<Rule> locale = new Rule(); in generate() local
104 locale->op = Rule::EQUALS; in generate()
105 locale->key = Rule::LANGUAGE; in generate()
108 locale->stringArgs.add(String8(str)); in generate()
109 rootRule->subrules.add(locale); in generate()
/frameworks/base/core/java/com/android/internal/inputmethod/
DInputMethodUtils.java202 return context.getResources().getConfiguration().locale; in getSystemLocaleFromContext()
216 @Nullable final Locale locale, final boolean checkCountry, in fillImes() argument
220 if (isSystemImeThatHasSubtypeOf(imi, context, checkDefaultAttribute, locale, in fillImes()
399 imi, context.getResources().getConfiguration().locale.getLanguage(), in isValidSystemDefaultIme()
413 @Nullable final Locale locale, final boolean checkCountry, final String mode) { in containsSubtypeOf() argument
414 if (locale == null) { in containsSubtypeOf()
423 if (!TextUtils.equals(subtype.getLocale(), locale.toString())) { in containsSubtypeOf()
429 if (!subtypeLocale.getLanguage().equals(locale.getLanguage())) { in containsSubtypeOf()
524 final String systemLocale = res.getConfiguration().locale.toString(); in getImplicitlyApplicableSubtypesLocked()
526 final String systemLanguage = res.getConfiguration().locale.getLanguage(); in getImplicitlyApplicableSubtypesLocked()
[all …]
/frameworks/base/include/androidfw/
DAssetManager.h133 void setLocale(const char* locale);
139 void setConfiguration(const ResTable_config& config, const char* locale = NULL);
249 const asset_path& path, const char* locale, const char* vendor);
250 String8 createPathNameLocked(const asset_path& path, const char* locale,
274 const asset_path& path, const char* locale, const char* vendor,
279 void setLocaleLocked(const char* locale);
/frameworks/base/docs/html/guide/topics/resources/
Dlocalization.jd14 <li>Android loads the correct resource set for the user's language and locale.</li>
61 differently depending on locale, then you would use Java to handle the data
78 <p>(This document focuses on localization and locale. For a complete description
97 device's locale.</p></td>
110 <p>Whenever the application runs in a locale for which you have not provided
111 locale-specific text, Android will load the default strings from
127 <li>When this application is launched on a device with locale set to English,
183 sounds, layouts, and other locale-specific resources. </p>
187 a different locale, you use a qualifier that specifies a language or a
200 files, each stored in a locale-specific resource directory:</p>
[all …]
/frameworks/av/media/libmedia/
DMediaScannerClient.cpp34 void MediaScannerClient::setLocale(const char* locale) in setLocale() argument
36 mLocale = locale; // not currently used in setLocale()

1234567