diff options
author | zachh <zachh@google.com> | 2017-08-15 18:13:03 -0700 |
---|---|---|
committer | Eric Erfanian <erfanian@google.com> | 2017-08-30 03:45:26 +0000 |
commit | 4e9a7930756e2e1dbfba20355f8f716987835a3a (patch) | |
tree | a4434a38478029d4f8c44396b0a2b82c20d90622 /java/com/android/dialer/calldetails/CallDetailsEntryViewHolder.java | |
parent | f1fa776384ceab6682ad86348e3d08e3ca2b983b (diff) |
Added a few more columns to annotated call log.
These are mostly columns that are just copied from the system call log.
Also refactored and implemented new logic for displaying call log durations and dates (not used yet).
Bug: 34672501
Test: existing and new
PiperOrigin-RevId: 165387731
Change-Id: I2bc736d848b5c10e42562e62beea64efdeed9c12
Diffstat (limited to 'java/com/android/dialer/calldetails/CallDetailsEntryViewHolder.java')
-rw-r--r-- | java/com/android/dialer/calldetails/CallDetailsEntryViewHolder.java | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/java/com/android/dialer/calldetails/CallDetailsEntryViewHolder.java b/java/com/android/dialer/calldetails/CallDetailsEntryViewHolder.java index 9c592fc5f..084bd667c 100644 --- a/java/com/android/dialer/calldetails/CallDetailsEntryViewHolder.java +++ b/java/com/android/dialer/calldetails/CallDetailsEntryViewHolder.java @@ -28,7 +28,8 @@ import android.view.View; import android.widget.ImageView; import android.widget.TextView; import com.android.dialer.calldetails.CallDetailsEntries.CallDetailsEntry; -import com.android.dialer.calllogutils.CallEntryFormatter; +import com.android.dialer.calllogutils.CallLogDates; +import com.android.dialer.calllogutils.CallLogDurations; import com.android.dialer.calllogutils.CallTypeHelper; import com.android.dialer.calllogutils.CallTypeIconsView; import com.android.dialer.common.LogUtil; @@ -103,16 +104,17 @@ public class CallDetailsEntryViewHolder extends ViewHolder { callTypeText.setText( callTypeHelper.getCallTypeText(callType, isVideoCall, isPulledCall, isLightbringerCall)); - callTime.setText(CallEntryFormatter.formatDate(context, entry.getDate())); + callTime.setText(CallLogDates.formatDate(context, entry.getDate())); + if (CallTypeHelper.isMissedCallType(callType)) { callDuration.setVisibility(View.GONE); } else { callDuration.setVisibility(View.VISIBLE); callDuration.setText( - CallEntryFormatter.formatDurationAndDataUsage( + CallLogDurations.formatDurationAndDataUsage( context, entry.getDuration(), entry.getDataUsage())); callDuration.setContentDescription( - CallEntryFormatter.formatDurationAndDataUsageA11y( + CallLogDurations.formatDurationAndDataUsageA11y( context, entry.getDuration(), entry.getDataUsage())); } setMultimediaDetails(number, entry, showMultimediaDivider); |