summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThe Android Automerger <android-build@android.com>2010-01-26 15:16:04 -0800
committerThe Android Automerger <android-build@android.com>2010-01-26 15:16:04 -0800
commit5a955cfe72b96a943774b43844c36551f0f5a242 (patch)
tree36189bca6eb63c2280def3217d2cffaa08be43a0
parentbb0135d1923734eee0d8078e4462310f81d0ddf9 (diff)
parent2cbf43b9b0429b4b09ed6f67abe56e20bcdf9f6a (diff)
downloadMms-eclair-release.tar.gz
-rw-r--r--src/com/android/mms/util/ContactInfoCache.java18
1 files changed, 6 insertions, 12 deletions
diff --git a/src/com/android/mms/util/ContactInfoCache.java b/src/com/android/mms/util/ContactInfoCache.java
index 72a21c67..fa7d495d 100644
--- a/src/com/android/mms/util/ContactInfoCache.java
+++ b/src/com/android/mms/util/ContactInfoCache.java
@@ -106,17 +106,9 @@ public class ContactInfoCache {
private final Context mContext;
- private String[] mContactInfoSelectionArgs = new String[1];
-
// cached contact info
private final HashMap<String, CacheEntry> mCache = new HashMap<String, CacheEntry>();
- // for background cache rebuilding
- private Thread mCacheRebuilder = null;
- private Object mCacheRebuildLock = new Object();
- private boolean mPhoneCacheInvalidated = false;
- private boolean mEmailCacheInvalidated = false;
-
/**
* CacheEntry stores the caller id or email lookup info.
*/
@@ -294,7 +286,8 @@ public class ContactInfoCache {
//if (LOCAL_DEBUG) log("queryContactInfoByNumber: number=" + number);
- mContactInfoSelectionArgs[0] = number;
+ String contactInfoSelectionArgs[] = new String[1];
+ contactInfoSelectionArgs[0] = number;
// We need to include the phone number in the selection string itself rather then
// selection arguments, because SQLite needs to see the exact pattern of GLOB
@@ -305,7 +298,7 @@ public class ContactInfoCache {
PHONES_WITH_PRESENCE_URI,
CALLER_ID_PROJECTION,
selection,
- mContactInfoSelectionArgs,
+ contactInfoSelectionArgs,
null);
if (cursor == null) {
@@ -476,13 +469,14 @@ public class ContactInfoCache {
private CacheEntry queryEmailDisplayName(String email) {
CacheEntry entry = new CacheEntry();
- mContactInfoSelectionArgs[0] = email;
+ String contactInfoSelectionArgs[] = new String[1];
+ contactInfoSelectionArgs[0] = email;
Cursor cursor = SqliteWrapper.query(mContext, mContext.getContentResolver(),
EMAIL_WITH_PRESENCE_URI,
EMAIL_PROJECTION,
EMAIL_SELECTION,
- mContactInfoSelectionArgs,
+ contactInfoSelectionArgs,
null);
if (cursor != null) {