aboutsummaryrefslogtreecommitdiffstats
path: root/java/src/com/android/inputmethod/latin/BinaryDictionaryGetter.java
diff options
context:
space:
mode:
authorKurt Partridge <kep@google.com>2013-06-05 22:11:20 -0700
committerKurt Partridge <kep@google.com>2013-06-05 22:14:54 -0700
commitefd26bb3192722c2980098a6f36dff6006e8896a (patch)
treee4b26777f657292d1b06438f76d0ed381d82e2c1 /java/src/com/android/inputmethod/latin/BinaryDictionaryGetter.java
parent9c440d137300ddf72cca201cf08c9bb2e32d6836 (diff)
downloadlatinime-efd26bb3192722c2980098a6f36dff6006e8896a.tar.gz
latinime-efd26bb3192722c2980098a6f36dff6006e8896a.tar.xz
latinime-efd26bb3192722c2980098a6f36dff6006e8896a.zip
Allow downloadable dictionaries in development builds
Bug: 9305379 Change-Id: Iab32753070a056d3861a45aa898911b7ab67dfb6
Diffstat (limited to '')
-rw-r--r--java/src/com/android/inputmethod/latin/BinaryDictionaryGetter.java16
1 files changed, 6 insertions, 10 deletions
diff --git a/java/src/com/android/inputmethod/latin/BinaryDictionaryGetter.java b/java/src/com/android/inputmethod/latin/BinaryDictionaryGetter.java
index 98eadcacb..272f36e4f 100644
--- a/java/src/com/android/inputmethod/latin/BinaryDictionaryGetter.java
+++ b/java/src/com/android/inputmethod/latin/BinaryDictionaryGetter.java
@@ -290,16 +290,12 @@ final class BinaryDictionaryGetter {
final Context context) {
final boolean hasDefaultWordList = DictionaryFactory.isDictionaryAvailable(context, locale);
- // TODO: The development-only-diagnostic version is not supported by the Dictionary Pack
- // Service yet
- if (!ProductionFlag.USES_DEVELOPMENT_ONLY_DIAGNOSTICS) {
- // We need internet access to do the following. Only do this if the package actually
- // has the permission.
- if (context.checkCallingOrSelfPermission(android.Manifest.permission.INTERNET)
- == PackageManager.PERMISSION_GRANTED) {
- BinaryDictionaryFileDumper.cacheWordListsFromContentProvider(locale, context,
- hasDefaultWordList);
- }
+ // We need internet access to do the following. Only do this if the package actually
+ // has the permission.
+ if (context.checkCallingOrSelfPermission(android.Manifest.permission.INTERNET)
+ == PackageManager.PERMISSION_GRANTED) {
+ BinaryDictionaryFileDumper.cacheWordListsFromContentProvider(locale, context,
+ hasDefaultWordList);
}
final File[] cachedWordLists = getCachedWordLists(locale.toString(), context);
final String mainDictId = DictionaryInfoUtils.getMainDictId(locale);