/frameworks/base/core/tests/coretests/src/android/os/ |
D | LocaleListTest.java | 36 @IgnoreUnderRavenwood(blockedBy = LocaleList.class) 44 LocaleList ll; in testConstructor() 45 ll = new LocaleList(Locale.forLanguageTag("fr"), null); in testConstructor() 48 ll = new LocaleList(Locale.forLanguageTag("fr"), LocaleList.getEmptyLocaleList()); in testConstructor() 51 ll = new LocaleList(Locale.forLanguageTag("fr"), LocaleList.forLanguageTags("fr")); in testConstructor() 54 ll = new LocaleList(Locale.forLanguageTag("fr"), LocaleList.forLanguageTags("de")); in testConstructor() 57 ll = new LocaleList(Locale.forLanguageTag("fr"), LocaleList.forLanguageTags("de,ja")); in testConstructor() 60 ll = new LocaleList(Locale.forLanguageTag("fr"), LocaleList.forLanguageTags("de,fr,ja")); in testConstructor() 63 ll = new LocaleList(Locale.forLanguageTag("fr"), LocaleList.forLanguageTags("de,fr")); in testConstructor() 66 ll = new LocaleList(Locale.forLanguageTag("fr"), LocaleList.forLanguageTags("fr,de")); in testConstructor() [all …]
|
/frameworks/base/services/tests/InputMethodSystemServerTests/src/com/android/server/inputmethod/ |
D | LocaleUtilsTest.java | 23 import android.os.LocaleList; 43 final LocaleList preferredLocales = LocaleList.getEmptyLocaleList(); in testFilterByLanguageEmptyLanguageList() 59 final LocaleList preferredLocales = LocaleList.forLanguageTags("zh-Hans-TW"); in testFilterDoesNotMatchAnything() 70 final LocaleList preferredLocales = LocaleList.forLanguageTags("fr,en-US,ja-JP"); in testFilterByLanguageEmptySource() 80 final LocaleList preferredLocales = in testFilterByLanguageNullAvailableLocales() 81 LocaleList.forLanguageTags("en-AU,en-GB,en-US,en,en-IN"); in testFilterByLanguageNullAvailableLocales() 89 final LocaleList preferredLocales = in testFilterByLanguageNullAvailableLocales() 90 LocaleList.forLanguageTags("en-AU,en-GB,en-US,en,en-IN"); in testFilterByLanguageNullAvailableLocales() 100 final LocaleList preferredLocales = in testFilterByLanguageNullAvailableLocales() 101 LocaleList.forLanguageTags("en-AU,en-GB,en-US,en,en-IN"); in testFilterByLanguageNullAvailableLocales() [all …]
|
/frameworks/base/packages/SettingsProvider/test/src/com/android/providers/settings/ |
D | SettingsHelperTest.java | 42 import android.os.LocaleList; 230 assertEquals(LocaleList.forLanguageTags("en-US"), in testResolveLocales() 232 LocaleList.forLanguageTags(""), // restore in testResolveLocales() 233 LocaleList.forLanguageTags("en-US"), // current in testResolveLocales() 237 assertEquals(LocaleList.forLanguageTags("en-US"), in testResolveLocales() 239 LocaleList.forLanguageTags("en-US"), // restore in testResolveLocales() 240 LocaleList.forLanguageTags("en-US"), // current in testResolveLocales() 243 assertEquals(LocaleList.forLanguageTags("en-US,ja-JP"), in testResolveLocales() 245 LocaleList.forLanguageTags("en-US,ja-JP"), // restore in testResolveLocales() 246 LocaleList.forLanguageTags("en-US,ja-JP"), // current in testResolveLocales() [all …]
|
/frameworks/base/services/core/java/com/android/server/wm/ |
D | LocaleOverlayHelper.java | 19 import android.os.LocaleList; 37 static LocaleList combineLocalesIfOverlayExists(LocaleList overlayLocales, in combineLocalesIfOverlayExists() 38 LocaleList baseLocales) { in combineLocalesIfOverlayExists() 49 private static LocaleList combineLocales(LocaleList overlayLocales, LocaleList baseLocales) { in combineLocales() 58 return new LocaleList(combinedLocales); in combineLocales()
|
D | PackageConfigurationUpdaterImpl.java | 22 import android.os.LocaleList; 36 private LocaleList mLocales; 66 setLocales(LocaleList locales) { in setLocales() 122 LocaleList localesOverride = LocaleOverlayHelper.combineLocalesIfOverlayExists( in updateConfig() 140 LocaleList getLocales() { in getLocales()
|
/frameworks/base/tests/Internal/src/com/android/internal/app/ |
D | LocaleStoreTest.java | 23 import android.os.LocaleList; 90 LocaleList.getEmptyLocaleList(), supportedLocale); in convertExplicitLocales_noExplicitLcoales_returnEmptyHashMap() 98 LocaleList localelist = new LocaleList(locales); in convertExplicitLocales_hasEmptyLocale_receiveException() 113 LocaleList locales = LocaleList.forLanguageTags("en-US,en-US"); in convertExplicitLocales_hasSameLocale_returnNonSameLocales() 125 LocaleList locales = LocaleList.forLanguageTags("en-US,ja-JP"); in convertExplicitLocales_hasEnUs_resultHasParentEn() 136 LocaleList locales = LocaleList.forLanguageTags("zh-TW,en-US,en"); in convertExplicitLocales_hasZhTw_resultZhHantTw() 147 LocaleList locales = LocaleList.forLanguageTags("de-1996,de-1901"); in convertExplicitLocales_nonRegularFormat_resultEmptyContry() 159 LocaleList locales = LocaleList.forLanguageTags("en-Latn-US,en-US,en"); in convertExplicitLocales_differentEnFormat() 171 LocaleList testSupportedLocales = in getLevelLocales_languageTier_returnAllSupportLanguages() 172 LocaleList.forLanguageTags( in getLevelLocales_languageTier_returnAllSupportLanguages() [all …]
|
/frameworks/base/core/java/android/os/ |
D | LocaleList.java | 40 public final class LocaleList implements Parcelable { class 49 private static final LocaleList sEmptyLocaleList = new LocaleList(); 101 if (!(other instanceof LocaleList)) in equals() 103 final Locale[] otherList = ((LocaleList) other).mList; in equals() 160 public Locale[] getIntersection(@NonNull LocaleList other) { in getIntersection() 182 public LocaleList(@NonNull Locale... list) { in LocaleList() method in LocaleList 217 public LocaleList(@NonNull Locale topLocale, LocaleList otherLocales) { in LocaleList() method in LocaleList 260 public static final @android.annotation.NonNull Parcelable.Creator<LocaleList> CREATOR 261 = new Parcelable.Creator<LocaleList>() { 263 public LocaleList createFromParcel(Parcel source) { [all …]
|
/frameworks/base/core/java/android/text/style/ |
D | LocaleSpan.java | 22 import android.os.LocaleList; 37 private final LocaleList mLocales; 53 mLocales = locale == null ? LocaleList.getEmptyLocaleList() : new LocaleList(locale); in LocaleSpan() 62 public LocaleSpan(@NonNull LocaleList locales) { in LocaleSpan() 68 mLocales = LocaleList.CREATOR.createFromParcel(source); in LocaleSpan() 112 public LocaleList getLocales() { in getLocales() 126 private static void apply(@NonNull Paint paint, @NonNull LocaleList locales) { in apply()
|
/frameworks/base/services/core/java/com/android/server/inputmethod/ |
D | SystemLocaleWrapper.java | 27 import android.os.LocaleList; 43 private static final AtomicReference<LocaleList> sSystemLocale = 44 new AtomicReference<>(new LocaleList(Locale.getDefault())); 57 static LocaleList get(@UserIdInt int userId) { in get() 68 void onLocaleChanged(@NonNull LocaleList prevLocales, @NonNull LocaleList newLocales); in onLocaleChanged() 101 final LocaleList newLocales = mContext.getResources().getConfiguration().getLocales(); in onReceive() 102 final LocaleList prevLocales = sSystemLocale.getAndSet(newLocales); in onReceive()
|
/frameworks/base/services/core/java/com/android/server/locales/ |
D | LocaleManagerShellCommand.java | 22 import android.os.LocaleList; 102 LocaleList locales = LocaleList.getEmptyLocaleList(); in runSetAppLocales() 162 LocaleList locales = mBinderService.getApplicationLocales(packageName, userId); in runGetAppLocales() 183 LocaleList locales = null; in runSetAppOverrideLocaleConfig() 242 LocaleList locales = localeConfig.getSupportedLocales(); in runGetAppOverrideLocaleConfig() 264 private LocaleList parseOverrideLocales() { in parseOverrideLocales() 269 return LocaleList.getEmptyLocaleList(); in parseOverrideLocales() 274 return LocaleList.forLanguageTags(locales); in parseOverrideLocales() 278 private LocaleList parseLocales() { in parseLocales() 281 return LocaleList.getEmptyLocaleList(); in parseLocales() [all …]
|
D | LocaleManagerService.java | 38 import android.os.LocaleList; 184 @NonNull LocaleList locales, boolean fromDelegate) throws RemoteException { in setApplicationLocales() 194 public LocaleList getApplicationLocales(@NonNull String appPackageName, in getApplicationLocales() 201 public LocaleList getSystemLocales() throws RemoteException { in getSystemLocales() 232 @NonNull LocaleList locales, boolean fromDelegate, int caller) in setApplicationLocales() 273 @UserIdInt int userId, @NonNull LocaleList locales, in setApplicationLocalesUnchecked() 308 LocaleList locales) { in notifyRegisteredReceivers() 325 LocaleList locales) { in notifyInstallerOfAppWhoseLocaleChanged() 341 LocaleList locales) { in notifyAppWhoseLocaleChanged() 350 LocaleList locales) { in createBaseIntent() [all …]
|
/frameworks/minikin/libs/minikin/ |
D | Locale.h | 39 class LocaleList; variable 136 int calcScoreFor(const LocaleList& supported) const; 154 friend class LocaleList; // for LocaleList constructor 202 class LocaleList { 204 explicit LocaleList(std::vector<Locale>&& locales); 205 LocaleList() in LocaleList() function 209 LocaleList(LocaleList&&) = default; 221 bool atLeastOneScriptMatch(const LocaleList& list) const; 243 LocaleList(const LocaleList&) = delete; 244 void operator=(const LocaleList&) = delete;
|
/frameworks/base/core/java/android/app/ |
D | LocaleManager.java | 29 import android.os.LocaleList; 75 public void setApplicationLocales(@NonNull LocaleList locales) { in setApplicationLocales() 104 public void setApplicationLocales(@NonNull String appPackageName, @NonNull LocaleList locales) { in setApplicationLocales() 108 private void setApplicationLocales(@NonNull String appPackageName, @NonNull LocaleList locales, in setApplicationLocales() 125 public LocaleList getApplicationLocales() { in getApplicationLocales() 147 public LocaleList getApplicationLocales(@NonNull String appPackageName) { in getApplicationLocales() 167 public LocaleList getSystemLocales() { in getSystemLocales() 181 public void setSystemLocales(@NonNull LocaleList locales) { in setSystemLocales()
|
D | ILocaleManager.aidl | 21 import android.os.LocaleList; 36 …void setApplicationLocales(String packageName, int userId, in LocaleList locales, boolean fromDele… in setApplicationLocales() 41 LocaleList getApplicationLocales(String packageName, int userId); in getApplicationLocales() 46 LocaleList getSystemLocales(); in getSystemLocales()
|
D | LocaleConfig.java | 28 import android.os.LocaleList; 71 private LocaleList mLocales; 176 public LocaleConfig(@NonNull LocaleList locales) { in LocaleConfig() 190 mLocales = in.readTypedObject(LocaleList.CREATOR); in LocaleConfig() 226 mLocales = LocaleList.forLanguageTags(String.join(",", localeNames)); in parseLocaleConfig() 246 public @Nullable LocaleList getSupportedLocales() { in getSupportedLocales() 328 LocaleList otherLocales = other.mLocales; in isSameLocaleConfig() 360 if (LocaleList.matchesLanguageAndScript(mLocales.get(i), locale)) { in containsLocale()
|
/frameworks/base/core/java/android/view/accessibility/ |
D | AccessibilityWindowAttributes.java | 20 import android.os.LocaleList; 36 private final LocaleList mLocales; 39 @NonNull LocaleList locales) { in AccessibilityWindowAttributes() 46 LocaleList inLocales = in.readParcelable(null, LocaleList.class); in AccessibilityWindowAttributes() 50 mLocales = LocaleList.getEmptyLocaleList(); in AccessibilityWindowAttributes() 78 public @NonNull LocaleList getLocales() { in getLocales()
|
/frameworks/base/services/tests/wmtests/src/com/android/server/wm/ |
D | ActivityTaskManagerServiceTests.java | 66 import android.os.LocaleList; 679 config.setLocales(LocaleList.forLanguageTags("en-XC")); in testPackageConfigUpdate_locales_successfullyApplied() 686 packageConfigUpdater.setLocales(LocaleList.forLanguageTags("en-XA,ar-XB")).commit(); in testPackageConfigUpdate_locales_successfullyApplied() 691 assertEquals(LocaleList.forLanguageTags("en-XA,ar-XB,en-XC"), in testPackageConfigUpdate_locales_successfullyApplied() 699 config.setLocales(LocaleList.forLanguageTags("en-XC")); in testPackageConfigUpdate_nightMode_successfullyApplied() 711 assertEquals(LocaleList.forLanguageTags("en-XC"), in testPackageConfigUpdate_nightMode_successfullyApplied() 718 config.setLocales(LocaleList.forLanguageTags("en-XC")); in testPackageConfigUpdate_multipleLocaleUpdates_successfullyApplied() 726 packageConfigUpdater.setLocales(LocaleList.forLanguageTags("en-XA,ar-XB")) in testPackageConfigUpdate_multipleLocaleUpdates_successfullyApplied() 731 assertEquals(LocaleList.forLanguageTags("en-XA,ar-XB,en-XC"), in testPackageConfigUpdate_multipleLocaleUpdates_successfullyApplied() 734 assertEquals(LocaleList.forLanguageTags("en-XA,ar-XB,en-XC"), in testPackageConfigUpdate_multipleLocaleUpdates_successfullyApplied() [all …]
|
/frameworks/base/services/tests/servicestests/src/com/android/server/locales/ |
D | FakePackageConfigurationUpdater.java | 22 import android.os.LocaleList; 36 LocaleList mLocales = null; 44 public PackageConfigurationUpdater setLocales(LocaleList locales) { in setLocales() 65 LocaleList getStoredLocales() { in getStoredLocales()
|
D | LocaleManagerServiceTest.java | 48 import android.os.LocaleList; 75 private static final LocaleList DEFAULT_LOCALES = 76 LocaleList.forLanguageTags(DEFAULT_LOCALE_TAGS); 141 LocaleList.getEmptyLocaleList(), false, FrameworkStatsLog in testSetApplicationLocales_arbitraryAppWithoutPermissions_fails() 157 DEFAULT_USER_ID, LocaleList.getEmptyLocaleList(), false, in testSetApplicationLocales_nullPackageName_fails() 218 LocaleList.getEmptyLocaleList(), false, FrameworkStatsLog in testSetApplicationLocales_invalidPackageOrUserId_fails() 277 LocaleList locales = mLocaleManagerService.getApplicationLocales( in testGetApplicationLocales_appSpecificConfigAbsent_returnsEmptyList() 280 assertEquals(LocaleList.getEmptyLocaleList(), locales); in testGetApplicationLocales_appSpecificConfigAbsent_returnsEmptyList() 293 LocaleList locales = mLocaleManagerService.getApplicationLocales( in testGetApplicationLocales_appSpecificLocalesAbsent_returnsEmptyList() 296 assertEquals(LocaleList.getEmptyLocaleList(), locales); in testGetApplicationLocales_appSpecificLocalesAbsent_returnsEmptyList() [all …]
|
D | LocaleManagerBackupRestoreTest.java | 46 import android.os.LocaleList; 102 private static final LocaleList DEFAULT_LOCALES = 103 LocaleList.forLanguageTags(DEFAULT_LOCALE_TAGS); 196 setUpLocalesForPackage(DEFAULT_PACKAGE_NAME, LocaleList.getEmptyLocaleList()); in testBackupPayload_noAppLocalesSet_returnsNull() 278 setUpLocalesForPackage(DEFAULT_PACKAGE_NAME, LocaleList.getEmptyLocaleList()); in testRestore_allAppsInstalled_noStageDataCreated() 294 setUpLocalesForPackage(DEFAULT_PACKAGE_NAME, LocaleList.getEmptyLocaleList()); in testRestore_allAppsInstalled_nothingToSp() 318 setUpLocalesForPackage(DEFAULT_PACKAGE_NAME, LocaleList.getEmptyLocaleList()); in testRestore_allAppsInstalled_storeInfoToSp() 343 setUpLocalesForPackage(DEFAULT_PACKAGE_NAME, LocaleList.getEmptyLocaleList()); in testRestore_allAppsInstalled_InfoHasExistedInSp() 388 setUpLocalesForPackage(pkgNameA, LocaleList.getEmptyLocaleList()); in testRestore_someAppsInstalled_partiallyStaged() 393 LocaleList.forLanguageTags(langTagsA), true, FrameworkStatsLog in testRestore_someAppsInstalled_partiallyStaged() [all …]
|
/frameworks/base/core/tests/coretests/src/android/content/res/ |
D | ResourcesLocaleTest.java | 21 import android.os.LocaleList; 73 final LocaleList preferredLocales = LocaleList.forLanguageTags("en-US,pl-PL"); in testEnglishIsAlwaysConsideredSupported() 90 final LocaleList preferredLocales = LocaleList.forLanguageTags("fr-FR,pl-PL"); in testSelectFirstSupportedLanguage() 115 LocaleList locales = new LocaleList(locale); in assertResGetString()
|
/frameworks/base/core/tests/coretests/src/android/text/util/ |
D | LinkifyTest.java | 25 import android.os.LocaleList; 51 private static final LocaleList LOCALE_LIST_US = new LocaleList(Locale.US); 52 private LocaleList mOriginalLocales; 58 mOriginalLocales = LocaleList.getDefault(); in setup() 59 LocaleList.setDefault(LOCALE_LIST_US); in setup() 64 LocaleList.setDefault(mOriginalLocales); in teardown()
|
/frameworks/base/core/java/com/android/internal/app/ |
D | SystemLocaleCollector.java | 20 import android.os.LocaleList; 29 private LocaleList mExplicitLocales; 35 SystemLocaleCollector(Context context, LocaleList explicitLocales) { in SystemLocaleCollector() 44 final LocaleList userLocales = LocalePicker.getLocales(); in getIgnoredLocaleList()
|
/frameworks/base/core/tests/coretests/src/android/view/accessibility/ |
D | AccessibilityWindowAttributesTest.java | 23 import android.os.LocaleList; 43 private static final LocaleList TEST_LOCALES = new LocaleList(Locale.ROOT); 76 String windowTitle, LocaleList locales) { in createInstance()
|
/frameworks/base/core/java/android/view/inputmethod/ |
D | InlineSuggestionsRequest.java | 28 import android.os.LocaleList; 82 private @NonNull LocaleList mSupportedLocales; 185 private static LocaleList defaultSupportedLocales() { in defaultSupportedLocales() 187 return LocaleList.getEmptyLocaleList(); in defaultSupportedLocales() 189 return LocaleList.getDefault(); in defaultSupportedLocales() 237 @NonNull LocaleList supportedLocales, in InlineSuggestionsRequest() 303 public @NonNull LocaleList getSupportedLocales() { in getSupportedLocales() 443 LocaleList supportedLocales = (LocaleList) in.readTypedObject(LocaleList.CREATOR); in InlineSuggestionsRequest() 493 private @NonNull LocaleList mSupportedLocales; 578 public @NonNull Builder setSupportedLocales(@NonNull LocaleList value) { in setSupportedLocales()
|