Add Cequint contact lookup result type.

Bug: 73741286
Test: none
PiperOrigin-RevId: 189377028
Change-Id: Ifb9c6375d0026fb012ae868741b471f2ca02c5f9
diff --git a/java/com/android/dialer/logging/contact_lookup_result.proto b/java/com/android/dialer/logging/contact_lookup_result.proto
index 673ade7..6dda2a6 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 @@
     // 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 7a5002d..fd9855f 100644
--- a/java/com/android/incallui/CallerInfo.java
+++ b/java/com/android/incallui/CallerInfo.java
@@ -35,6 +35,7 @@
 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 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 @@
     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 9051338..b79fd64 100644
--- a/java/com/android/incallui/ContactInfoCache.java
+++ b/java/com/android/incallui/ContactInfoCache.java
@@ -276,7 +276,7 @@
     cce.isVoicemailNumber = info.isVoiceMailNumber();
 
     if (info.contactExists) {
-      cce.contactLookupResult = ContactLookupResult.Type.LOCAL_CONTACT;
+      cce.contactLookupResult = info.contactLookupResultType;
     }
   }
 
@@ -543,6 +543,7 @@
     // Set contact to exist to avoid phone number service lookup.
     if (hasUpdate) {
       callerInfo.contactExists = true;
+      callerInfo.contactLookupResultType = ContactLookupResult.Type.CEQUINT;
     }
   }