diff options
author | Dmitri Plotnikov <dplotnikov@google.com> | 2010-03-17 21:47:35 -0700 |
---|---|---|
committer | Dmitri Plotnikov <dplotnikov@google.com> | 2010-03-17 21:47:35 -0700 |
commit | e709da26d02cc55c553f14e20233ddddd408936b (patch) | |
tree | cdfc6600233d4745afd97bcbf5f713e55a5de960 | |
parent | 1391e03254ce442022e05e473f1a5e322411150c (diff) | |
download | ContactsProvider-e709da26d02cc55c553f14e20233ddddd408936b.tar.gz |
Fixing SUSPENDED contact aggregation mode
Change-Id: I50aaf86a653d0b3e147937edad3e7a634b86d9e7
-rw-r--r-- | src/com/android/providers/contacts/ContactAggregator.java | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/com/android/providers/contacts/ContactAggregator.java b/src/com/android/providers/contacts/ContactAggregator.java index e7cecbf2..1e239a27 100644 --- a/src/com/android/providers/contacts/ContactAggregator.java +++ b/src/com/android/providers/contacts/ContactAggregator.java @@ -484,7 +484,11 @@ public class ContactAggregator { } // If there are no other raw contacts in the current aggregate, we might as well reuse it. - if (contactId == -1 && currentContactId != 0 && currentContactContentsCount == 0) { + // Also, if the aggregation mode is SUSPENDED, we must reuse the same aggregate. + if (contactId == -1 + && currentContactId != 0 + && (currentContactContentsCount == 0 + || aggregationMode == RawContacts.AGGREGATION_MODE_SUSPENDED)) { contactId = currentContactId; } |