From edb22da2b40549631a08150cbfc205e6ad243c20 Mon Sep 17 00:00:00 2001 From: Andrew Lee Date: Tue, 9 Jun 2015 18:22:14 -0700 Subject: Change PhoneCallDetail fields to be non-final. It's been a pain to add/change fields on PhoneCallDetails because a multitude of parameters required for the constructors to create an instance. I ran into this while considering how to add an objectId to its parameters, and have previously too... Make fields non-final so that they are more easily set. This has the side-effect of making the casing of some initialization code more straightforward. + Change it's constructor to a subset of required fields. + Simplify/reorganize CallLogAdapter and CallLogAsyncTaskUtil code. + Simplify tests. Bug: 21733599 Change-Id: I236dfb0b8e6513f4b44dbdae17ce2eb9c9ae4778 --- src/com/android/dialer/calllog/DefaultVoicemailNotifier.java | 5 ----- 1 file changed, 5 deletions(-) (limited to 'src/com/android/dialer/calllog/DefaultVoicemailNotifier.java') diff --git a/src/com/android/dialer/calllog/DefaultVoicemailNotifier.java b/src/com/android/dialer/calllog/DefaultVoicemailNotifier.java index 7c2a96638..942a73fb4 100644 --- a/src/com/android/dialer/calllog/DefaultVoicemailNotifier.java +++ b/src/com/android/dialer/calllog/DefaultVoicemailNotifier.java @@ -28,7 +28,6 @@ import android.database.Cursor; import android.net.Uri; import android.provider.CallLog.Calls; import android.provider.ContactsContract.PhoneLookup; -import android.telecom.PhoneAccountHandle; import android.text.TextUtils; import android.util.Log; @@ -122,12 +121,8 @@ public class DefaultVoicemailNotifier { // Check if we already know the name associated with this number. String name = names.get(newCall.number); if (name == null) { - PhoneAccountHandle accountHandle = PhoneAccountUtils.getAccount( - newCall.accountComponentName, - newCall.accountId); name = PhoneNumberDisplayUtil.getDisplayName( mContext, - accountHandle, newCall.number, newCall.numberPresentation, /* isVoicemail */ false).toString(); -- cgit v1.2.3