aboutsummaryrefslogtreecommitdiffstats
path: root/java/src/com/android/inputmethod/latin/AutoDictionary.java
diff options
context:
space:
mode:
authorJae Yong Sung <jysung@google.com>2010-08-03 18:28:38 -0700
committerJae Yong Sung <jysung@google.com>2010-08-10 13:30:58 -0700
commitac093396ba20437a240dbcf4e2b35f9d5355bd6c (patch)
tree5d6cdff18ec7266a1f4461159aa1a011fe386c02 /java/src/com/android/inputmethod/latin/AutoDictionary.java
parent6dea4254808017374af47b126f179c515bd544a9 (diff)
downloadlatinime-ac093396ba20437a240dbcf4e2b35f9d5355bd6c.tar.gz
latinime-ac093396ba20437a240dbcf4e2b35f9d5355bd6c.tar.xz
latinime-ac093396ba20437a240dbcf4e2b35f9d5355bd6c.zip
-UserBigram
-UnitTest for UserBigram -Changes for number of bigrams to load Change-Id: I2c6fbe6194d34112ccc52c7e199461d2350e8516
Diffstat (limited to '')
-rw-r--r--java/src/com/android/inputmethod/latin/AutoDictionary.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/java/src/com/android/inputmethod/latin/AutoDictionary.java b/java/src/com/android/inputmethod/latin/AutoDictionary.java
index 94331d3f2..4fbb5b012 100644
--- a/java/src/com/android/inputmethod/latin/AutoDictionary.java
+++ b/java/src/com/android/inputmethod/latin/AutoDictionary.java
@@ -83,14 +83,14 @@ public class AutoDictionary extends ExpandableDictionary {
sDictProjectionMap.put(COLUMN_LOCALE, COLUMN_LOCALE);
}
- private static DatabaseHelper mOpenHelper = null;
+ private static DatabaseHelper sOpenHelper = null;
public AutoDictionary(Context context, LatinIME ime, String locale, int dicTypeId) {
super(context, dicTypeId);
mIme = ime;
mLocale = locale;
- if (mOpenHelper == null) {
- mOpenHelper = new DatabaseHelper(getContext());
+ if (sOpenHelper == null) {
+ sOpenHelper = new DatabaseHelper(getContext());
}
if (mLocale != null && mLocale.length() > 1) {
loadDictionary();
@@ -169,7 +169,7 @@ public class AutoDictionary extends ExpandableDictionary {
// Nothing pending? Return
if (mPendingWrites.isEmpty()) return;
// Create a background thread to write the pending entries
- new UpdateDbTask(getContext(), mOpenHelper, mPendingWrites, mLocale).execute();
+ new UpdateDbTask(getContext(), sOpenHelper, mPendingWrites, mLocale).execute();
// Create a new map for writing new entries into while the old one is written to db
mPendingWrites = new HashMap<String, Integer>();
}
@@ -209,7 +209,7 @@ public class AutoDictionary extends ExpandableDictionary {
qb.setProjectionMap(sDictProjectionMap);
// Get the database and run the query
- SQLiteDatabase db = mOpenHelper.getReadableDatabase();
+ SQLiteDatabase db = sOpenHelper.getReadableDatabase();
Cursor c = qb.query(db, null, selection, selectionArgs, null, null,
DEFAULT_SORT_ORDER);
return c;