/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/ |
H A D | WordListInfo.java | 25 public WordListInfo(final String id, final String locale) { argument 27 mLocale = locale;
|
H A D | SynchronouslyLoadedUserDictionary.java | 25 public SynchronouslyLoadedUserDictionary(final Context context, final String locale) { argument 26 this(context, locale, false); 29 public SynchronouslyLoadedUserDictionary(final Context context, final String locale, argument 31 super(context, locale, alsoUseMoreRestrictiveLocales);
|
H A D | SubtypeLocale.java | 38 public static String getFullDisplayName(Locale locale) { argument 39 String localeCode = locale.toString(); 44 return locale.getDisplayName(locale);
|
H A D | DictionaryFactory.java | 40 * locale. If none is found, it falls back to using the resource passed as fallBackResId 43 * @param locale the locale for which to create the dictionary 49 final Locale locale, final int fallbackResId, final Flag[] flagArray) { 50 if (null == locale) { 51 Log.e(TAG, "No locale defined for dictionary"); 52 return new DictionaryCollection(createBinaryDictionary(context, fallbackResId, locale)); 57 BinaryDictionaryGetter.getDictionaryFiles(locale, context, fallbackResId); 78 * locale. If none is found, it falls back to using the resource passed as fallBackResId 81 * @param locale th 48 createDictionaryFromManager(final Context context, final Locale locale, final int fallbackResId, final Flag[] flagArray) argument 85 createDictionaryFromManager(final Context context, final Locale locale, final int fallbackResId) argument 97 createBinaryDictionary(final Context context, final int resId, final Locale locale) argument 163 isDictionaryAvailable(Context context, Locale locale) argument 181 getDictionaryId(final Context context, final Locale locale) argument [all...] |
H A D | BinaryDictionaryGetter.java | 116 * Find out the cache directory associated with a specific locale. 118 private static String getCacheDirectoryForLocale(final String locale, final Context context) { argument 119 final String relativeDirectoryName = replaceFileNameDangerousCharacters(locale); 125 Log.e(TAG, "Could not create the directory for locale" + locale); 132 * Generates a file name for the id and locale passed as an argument. 135 * any id/locale pair, but please do not expect that the id can be the same for 139 * named like the locale, except it will also escape characters that look dangerous 142 * @param locale the locale fo 146 getCacheFileName(String id, String locale, Context context) argument 154 loadFallbackResource(final Context context, final int fallbackResId, final Locale locale) argument 219 getCachedWordLists(final String locale, final Context context) argument 248 getMainDictId(final Locale locale) argument 267 getDictionaryFiles(final Locale locale, final Context context, final int fallbackResId) argument [all...] |
H A D | UserDictionary.java | 51 public UserDictionary(final Context context, final String locale) { argument 52 this(context, locale, false); 55 public UserDictionary(final Context context, final String locale, argument 58 if (null == locale) throw new NullPointerException(); // Catch the error earlier 59 mLocale = locale; 87 // Split the locale. For example "en" => ["en"], "de_DE" => ["de", "DE"], 89 // This is correct for locale processing. 95 final StringBuilder request = new StringBuilder("(locale is NULL)"); 98 // and request = "(locale is NULL)" 107 // 0 | "(locale i [all...] |
/packages/apps/Contacts/src/com/android/contacts/util/ |
H A D | PhonebookCollatorFactory.java | 34 final Locale locale; 36 locale = new Locale("ja@collation=phonebook"); 38 locale = defaultLocale; 41 return Collator.getInstance(locale);
|
/packages/apps/Settings/src/com/android/settings/ |
H A D | LocalePicker.java | 29 public void onLocaleSelected(Locale locale) { argument 31 LocalePicker.updateLocale(locale);
|
/packages/apps/Contacts/tests/src/com/android/contacts/util/ |
H A D | LocaleTestUtils.java | 26 * Utility class to save and restore the locale of the system. 28 * This can be used for tests that assume to be run in a certain locale, e.g., because they 30 * will behave in a specific locale. 32 * In your test, you can change the locale with the following code: 66 * Create a new instance that can be used to set and reset the locale for the given context. 68 * @param context the context on which to alter the locale 76 * Set the locale to the given value and saves the previous value. 78 * @param locale the value to which the locale should be set 79 * @throws IllegalStateException if the locale wa 81 setLocale(Locale locale) argument 112 setResourcesLocale(Resources resources, Locale locale) argument [all...] |
/packages/apps/Settings/src/com/android/settings/inputmethod/ |
H A D | UserDictionaryList.java | 58 String locale = cursor.getString(columnIndex); 59 localeList.add(null != locale ? locale : ""); 67 * Creates the entries that allow the user to go into the user dictionary for each locale. 78 for (String locale : localeList) { 79 userDictGroup.addPreference(createUserDictionaryPreference(locale, activity)); 86 * @param locale The locale for which this user dictionary is for. 89 protected Preference createUserDictionaryPreference(String locale, Activity activity) { argument 92 if (null == locale) { [all...] |
H A D | InputMethodAndLanguageSettings.java | 96 // No "Select language" pref if there's only one system locale available. 148 // The locale list is null if and only if the user dictionary service is 156 // If the size of localeList is 0, we don't set the locale parameter in the 158 // meaning "the current locale". 160 // the locale list always has at least one element, since it always includes the current 161 // locale explicitly. @see UserDictionaryList.getUserDictionaryLocalesList(). 163 final String locale = (String)localeList.toArray()[0]; 164 userDictionaryPreference.getExtras().putString("locale", locale); 178 String locale [all...] |
/packages/inputmethods/LatinIME/tests/src/com/android/inputmethod/latin/ |
H A D | SubtypeLocaleTests.java | 65 private String getStringWithLocale(int resId, Locale locale) { argument 68 Locale.setDefault(locale); 80 final Locale locale = LocaleUtils.constructLocaleFromString(localeCode); 81 // The locale name which will be displayed on spacebar. For example 'English (US)' or 83 final String displayName = SubtypeLocale.getFullDisplayName(locale); 84 // The subtype name in its locale. For example 'English (US) Keyboard' or 86 final String subtypeName = getStringWithLocale(subtype.getNameResId(), locale); 90 "subtype name is '%s' and should contain locale '%s' name '%s'\n",
|
H A D | UserBigramSuggestHelper.java | 34 final int userBigramDelete, final KeyboardId keyboardId, final Locale locale) { 35 super(context, dictionaryPath, startOffset, length, keyboardId, locale); 37 mUserBigram = new UserBigramDictionary(context, null, locale.toString(), 45 public void changeUserBigramLocale(Locale locale) { argument 49 mUserBigram = new UserBigramDictionary(mContext, null, locale.toString(), 32 UserBigramSuggestHelper(final Context context, final File dictionaryPath, final long startOffset, final long length, final int userBigramMax, final int userBigramDelete, final KeyboardId keyboardId, final Locale locale) argument
|
H A D | UserBigramSuggestTests.java | 36 final Locale locale = Locale.US; 40 createKeyboardId(locale, Configuration.ORIENTATION_PORTRAIT), locale); 58 * Test loading correct (locale) bigrams 62 isInSuggestions("bigram in default locale", 69 mHelper.searchUserBigramSuggestion("locale", 'f', "france")); 76 mHelper.searchUserBigramSuggestion("locale", 'f', "france")); 107 private static final String[] pair3 = {"locale", "france"};
|
H A D | SuggestTests.java | 33 final Locale locale = Locale.US; 36 createKeyboardId(locale, Configuration.ORIENTATION_PORTRAIT), locale);
|
H A D | SuggestTestsBase.java | 41 protected KeyboardId createKeyboardId(Locale locale, int orientation) { argument 53 return new KeyboardId(locale.toString() + " keyboard", 54 com.android.inputmethod.latin.R.xml.kbd_qwerty, locale, orientation, width,
|
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/deprecated/languageswitcher/ |
H A D | InputLanguageSelection.java | 62 public LocaleEntry(String label, Locale locale) { argument 64 this.mLocale = locale; 93 Locale locale = loc.mLocale; 94 final Pair<Long, Boolean> hasDictionaryOrLayout = hasDictionaryOrLayout(locale); 98 // Add this locale to the supported list if: 99 // 1) this locale has a layout/ 2) this locale has a dictionary 100 // If some locales have no layout but have a same dictionary, the shortest locale 112 final String newLocale = locale.toString(); 115 // Check if this locale i 148 isLocaleIn(Locale locale, String[] list) argument 156 hasDictionaryOrLayout(Locale locale) argument 182 get5Code(Locale locale) argument [all...] |
H A D | LanguageSwitcher.java | 63 final Locale newLocale = conf.locale; 72 * @param systemLocale the current system locale, stored for changing the current input language 73 * based on the system current system locale. 120 mDefaultInputLocale = mIme.getResources().getConfiguration().locale; 129 final Locale locale = LocaleUtils.constructLocaleFromString(lang); 130 mLocales.add(locale); 136 * no specific locale was selected for input. 155 * Returns the currently selected input locale, or the display locale if no specific 156 * locale wa 187 setSystemLocale(Locale locale) argument [all...] |
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/spellcheck/ |
H A D | DictionaryPool.java | 34 final Locale locale) { 38 mLocale = locale; 33 DictionaryPool(final int maxSize, final AndroidSpellCheckerService service, final Locale locale) argument
|
H A D | AndroidSpellCheckerService.java | 199 public Result getResults(final int capitalizeType, final Locale locale) { argument 230 mSuggestions.set(i, mSuggestions.get(i).toString().toUpperCase(locale)); 236 locale)); 287 private DictionaryPool getDictionaryPool(final String locale) { argument 288 DictionaryPool pool = mDictionaryPools.get(locale); 290 final Locale localeObject = LocaleUtils.constructLocaleFromString(locale); 292 mDictionaryPools.put(locale, pool); 297 public DictAndProximity createDictAndProximity(final Locale locale) { argument 302 DictionaryFactory.createDictionaryFromManager(this, locale, fallbackResourceId, 304 final String localeStr = locale [all...] |
/packages/apps/Tag/src/com/android/apps/tag/record/ |
H A D | TextRecord.java | 70 public String getSnippet(Context context, Locale locale) { argument 138 public static NdefRecord newTextRecord(String text, Locale locale) { argument 139 return newTextRecord(text, locale, true); 142 public static NdefRecord newTextRecord(String text, Locale locale, boolean encodeInUtf8) { argument 144 Preconditions.checkNotNull(locale); 146 byte[] langBytes = locale.getLanguage().getBytes(Charset.forName("US-ASCII"));
|
H A D | ParsedNdefRecord.java | 40 public String getSnippet(Context context, Locale locale) { argument
|
/packages/apps/Tag/src/com/android/apps/tag/message/ |
H A D | ParsedNdefMessage.java | 50 * most appropriate for the given {@code locale}. 52 public String getSnippet(Context context, Locale locale) { argument 80 return record.getSnippet(context, locale);
|
/packages/apps/Browser/src/com/android/browser/search/ |
H A D | SearchEngineInfo.java | 85 Locale locale = context.getResources().getConfiguration().locale; 86 StringBuilder language = new StringBuilder(locale.getLanguage()); 87 if (!TextUtils.isEmpty(locale.getCountry())) { 89 language.append(locale.getCountry());
|
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/compat/ |
H A D | InputMethodSubtypeCompatWrapper.java | 77 public InputMethodSubtypeCompatWrapper(int nameResId, int iconResId, String locale, argument 85 mDummyLocale = locale != null ? locale : ""; 139 final Locale locale = new Locale(getLocale()); 140 final String localeStr = locale.getDisplayName(); 183 private static int hashCodeInternal(int nameResId, int iconResId, String locale, argument 186 .hashCode(new Object[] { nameResId, iconResId, locale, mode, extraValue });
|