diff options
author | Treehugger Robot <treehugger-gerrit@google.com> | 2018-03-16 20:48:46 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2018-03-16 20:48:46 +0000 |
commit | 51d7805925a35fa7e84c1d235ea53519aabec9c5 (patch) | |
tree | 902dc330a95cf013b397dbb1473b0895b51790a9 /java/com | |
parent | 5d8174bbf342c5890374beb8a8856067f0dee080 (diff) | |
parent | 262b6f2355b93d0e282d39ef16d222a65d450d16 (diff) |
Merge "Add Cequint contact lookup result type."
Diffstat (limited to 'java/com')
-rw-r--r-- | java/com/android/dialer/logging/contact_lookup_result.proto | 3 | ||||
-rw-r--r-- | java/com/android/incallui/CallerInfo.java | 3 | ||||
-rw-r--r-- | java/com/android/incallui/ContactInfoCache.java | 3 |
3 files changed, 8 insertions, 1 deletions
diff --git a/java/com/android/dialer/logging/contact_lookup_result.proto b/java/com/android/dialer/logging/contact_lookup_result.proto index 673ade760..6dda2a6d8 100644 --- a/java/com/android/dialer/logging/contact_lookup_result.proto +++ b/java/com/android/dialer/logging/contact_lookup_result.proto @@ -100,5 +100,8 @@ message ContactLookupResult { // Number was found in Dialer's local cache and was originally identified // as REMOTE_KNOWLEDGE_GRAPH LOCAL_CACHE_REMOTE_KNOWLEDGE_GRAPH = 25; + + // Number was identified via Cequint caller ID. + CEQUINT = 26; } } diff --git a/java/com/android/incallui/CallerInfo.java b/java/com/android/incallui/CallerInfo.java index 7a5002d0e..fd9855f24 100644 --- a/java/com/android/incallui/CallerInfo.java +++ b/java/com/android/incallui/CallerInfo.java @@ -35,6 +35,7 @@ import android.text.TextUtils; import com.android.contacts.common.ContactsUtils; import com.android.contacts.common.ContactsUtils.UserType; import com.android.contacts.common.util.TelephonyManagerUtils; +import com.android.dialer.logging.ContactLookupResult; import com.android.dialer.phonenumbercache.ContactInfoHelper; import com.android.dialer.phonenumbercache.PhoneLookupUtil; import com.android.dialer.phonenumberutil.PhoneNumberHelper; @@ -110,6 +111,7 @@ public class CallerInfo { public int numberPresentation; public int namePresentation; public boolean contactExists; + public ContactLookupResult.Type contactLookupResultType = ContactLookupResult.Type.NOT_FOUND; public String phoneLabel; /* Split up the phoneLabel into number type and label name */ public int numberType; @@ -315,6 +317,7 @@ public class CallerInfo { columnIndex = cursor.getColumnIndex(PhoneLookup.SEND_TO_VOICEMAIL); info.shouldSendToVoicemail = (columnIndex != -1) && ((cursor.getInt(columnIndex)) == 1); info.contactExists = true; + info.contactLookupResultType = ContactLookupResult.Type.LOCAL_CONTACT; // Determine userType by directoryId and contactId final String directory = diff --git a/java/com/android/incallui/ContactInfoCache.java b/java/com/android/incallui/ContactInfoCache.java index 90513381e..b79fd641a 100644 --- a/java/com/android/incallui/ContactInfoCache.java +++ b/java/com/android/incallui/ContactInfoCache.java @@ -276,7 +276,7 @@ public class ContactInfoCache implements OnImageLoadCompleteListener { cce.isVoicemailNumber = info.isVoiceMailNumber(); if (info.contactExists) { - cce.contactLookupResult = ContactLookupResult.Type.LOCAL_CONTACT; + cce.contactLookupResult = info.contactLookupResultType; } } @@ -543,6 +543,7 @@ public class ContactInfoCache implements OnImageLoadCompleteListener { // Set contact to exist to avoid phone number service lookup. if (hasUpdate) { callerInfo.contactExists = true; + callerInfo.contactLookupResultType = ContactLookupResult.Type.CEQUINT; } } |