diff options
author | Chiao Cheng <chiaocheng@google.com> | 2013-10-02 17:34:46 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2013-10-02 17:34:46 +0000 |
commit | 04710264c91f83657c70ec0a6718a5be0a65e080 (patch) | |
tree | 956325f64a1626ea4a743ca6fb6e8ab51354ea68 /src | |
parent | 8e5c8b11eb9516fa9b8407e0aa16c0405b5e717e (diff) | |
parent | 9fd02a6742c8e9139a03d80bacca360238be11bf (diff) |
Merge "Turn on reverse lookup by default." into klp-dev
Diffstat (limited to 'src')
-rw-r--r-- | src/com/android/dialer/calllog/CallLogAdapter.java | 11 | ||||
-rw-r--r-- | src/com/android/dialer/calllog/ContactInfo.java | 2 |
2 files changed, 8 insertions, 5 deletions
diff --git a/src/com/android/dialer/calllog/CallLogAdapter.java b/src/com/android/dialer/calllog/CallLogAdapter.java index 4bc1787e5..b2e520632 100644 --- a/src/com/android/dialer/calllog/CallLogAdapter.java +++ b/src/com/android/dialer/calllog/CallLogAdapter.java @@ -640,7 +640,13 @@ public class CallLogAdapter extends GroupingListAdapter if (!mIsCallLog) { final int numMissed = getNumMissedCalls(callType); final ViewStub stub = (ViewStub) view.findViewById(R.id.link_stub); + if (shouldShowBadge(numMissed, info, details)) { + // Do not process if the data has not changed (optimization since bind view is + // called multiple times due to contact lookup). + if (numMissed == mNumMissedCallsShown) { + return; + } // stub will be null if it was already inflated. if (stub != null) { @@ -718,11 +724,6 @@ public class CallLogAdapter extends GroupingListAdapter */ protected boolean shouldShowBadge(int numMissedCalls, ContactInfo info, PhoneCallDetails details) { - // Do not process if the data has not changed (optimization since bind view is called - // multiple times due to contact lookup). - if (numMissedCalls == mNumMissedCallsShown) { - return false; - } return numMissedCalls > 0; } diff --git a/src/com/android/dialer/calllog/ContactInfo.java b/src/com/android/dialer/calllog/ContactInfo.java index 2006744d3..601f55289 100644 --- a/src/com/android/dialer/calllog/ContactInfo.java +++ b/src/com/android/dialer/calllog/ContactInfo.java @@ -42,6 +42,8 @@ public class ContactInfo { public static String GEOCODE_AS_LABEL = ""; + public int sourceType = 0; + @Override public int hashCode() { // Uses only name and contactUri to determine hashcode. |