summaryrefslogtreecommitdiff
path: root/java/com/android/dialer/calllogutils/PhoneCallDetails.java
diff options
context:
space:
mode:
authortwyen <twyen@google.com>2018-06-26 16:04:53 -0700
committerandroid-build-merger <android-build-merger@google.com>2018-06-26 16:04:53 -0700
commitbfd105673cd6eb21a1c207d24169ad9bfe645539 (patch)
tree198fcf37848a75c8d68f74679a56fd9dc0f4891b /java/com/android/dialer/calllogutils/PhoneCallDetails.java
parentee0371753257a3db0cce37f5dffae7ac6ebf34b2 (diff)
parentf9d508090cbf3b9f85b72241c77f625c152448bc (diff)
Merge changes I45374e61,I265dcc61,Id4622886,I09d0df69,I3ea0fb46 am: 2f6900466e am: e6262b0bce
am: f9d508090c Change-Id: I329713a5083f5ccd632b536e41f466eaef9dc4e2
Diffstat (limited to 'java/com/android/dialer/calllogutils/PhoneCallDetails.java')
-rw-r--r--java/com/android/dialer/calllogutils/PhoneCallDetails.java7
1 files changed, 3 insertions, 4 deletions
diff --git a/java/com/android/dialer/calllogutils/PhoneCallDetails.java b/java/com/android/dialer/calllogutils/PhoneCallDetails.java
index fe8bfde43..7212fa960 100644
--- a/java/com/android/dialer/calllogutils/PhoneCallDetails.java
+++ b/java/com/android/dialer/calllogutils/PhoneCallDetails.java
@@ -25,8 +25,8 @@ import android.support.annotation.Nullable;
import android.telecom.PhoneAccountHandle;
import android.text.TextUtils;
import com.android.contacts.common.ContactsUtils.UserType;
-import com.android.contacts.common.preference.ContactsPreferences;
import com.android.contacts.common.util.ContactDisplayUtils;
+import com.android.dialer.contacts.displaypreference.ContactDisplayPreferences.DisplayOrder;
import com.android.dialer.logging.ContactSource;
import com.android.dialer.phonenumbercache.ContactInfo;
@@ -65,7 +65,7 @@ public class PhoneCallDetails {
* The user's preference on name display order, last name first or first time first. {@see
* ContactsPreferences}
*/
- public int nameDisplayOrder;
+ public DisplayOrder nameDisplayOrder;
// The type of phone, e.g., {@link Phone#TYPE_HOME}, 0 if not available.
public int numberType;
// The custom label associated with the phone number in the contact, or the empty string.
@@ -183,8 +183,7 @@ public class PhoneCallDetails {
* @return the preferred name
*/
public CharSequence getPreferredName() {
- if (nameDisplayOrder == ContactsPreferences.DISPLAY_ORDER_PRIMARY
- || TextUtils.isEmpty(nameAlternative)) {
+ if (nameDisplayOrder == DisplayOrder.PRIMARY || TextUtils.isEmpty(nameAlternative)) {
return namePrimary;
}
return nameAlternative;