diff options
author | Treehugger Robot <treehugger-gerrit@google.com> | 2018-01-22 21:12:49 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2018-01-22 21:12:49 +0000 |
commit | e5a20898faa4c66758a30d12e9245f15d6685a37 (patch) | |
tree | 14dd875eb4e6aab3c01ce710cce31fb027815379 /java/com/android/dialer/calllogutils/CallLogEntryText.java | |
parent | b762f4797502270f9c05e2f1774b6f06f917171f (diff) | |
parent | 5680b01ecb566e60a63c3a3362ec31f912cef692 (diff) |
Merge changes I84b69953,Ic996a314
* changes:
Properly display date and/or time of entries in the new call log.
Add simulator enriched call related to interfaces and stubs.
Diffstat (limited to 'java/com/android/dialer/calllogutils/CallLogEntryText.java')
-rw-r--r-- | java/com/android/dialer/calllogutils/CallLogEntryText.java | 31 |
1 files changed, 17 insertions, 14 deletions
diff --git a/java/com/android/dialer/calllogutils/CallLogEntryText.java b/java/com/android/dialer/calllogutils/CallLogEntryText.java index 1df44583f..25fe86452 100644 --- a/java/com/android/dialer/calllogutils/CallLogEntryText.java +++ b/java/com/android/dialer/calllogutils/CallLogEntryText.java @@ -49,22 +49,25 @@ public final class CallLogEntryText { return primaryText.toString(); } - /** The secondary text to show in the main call log entry list. */ + /** + * The secondary text to show in the main call log entry list. + * + * <p>Rules: (Duo video, )?$Label|$Location • Date + * + * <p>Examples: + * + * <ul> + * <li>Duo Video, Mobile • Now + * <li>Duo Video • 10 min. ago + * <li>Mobile • 11:45 PM + * <li>Mobile • Sun + * <li>Brooklyn, NJ • Jan 15 + * </ul> + * + * <p>See {@link CallLogDates#newCallLogTimestampLabel(Context, long, long)} for date rules. + */ public static CharSequence buildSecondaryTextForEntries( Context context, Clock clock, CoalescedRow row) { - /* - * Rules: (Duo video, )?$Label|$Location • Date - * - * Examples: - * Duo Video, Mobile • Now - * Duo Video • 11:45pm - * Mobile • 11:45pm - * Mobile • Sunday - * Brooklyn, NJ • Jan 15 - * - * Date rules: - * if < 1 minute ago: "Now"; else if today: HH:MM(am|pm); else if < 3 days: day; else: MON D - */ StringBuilder secondaryText = secondaryTextPrefix(context, row); if (secondaryText.length() > 0) { |