updating the SampleSyncAdapter sample to add stream item and photo code
Change-Id: I6d44ea3f912a3d1e52695bda785c81ff527160d5
This commit is contained in:
@@ -115,8 +115,21 @@ public class SyncAdapter extends AbstractThreadedSyncAdapter {
|
||||
// 2-way contact sync providers - it's more likely that one-way
|
||||
// sync providers (IM clients, social networking apps, etc) would
|
||||
// use this feature.
|
||||
|
||||
ContactManager.updateStatusMessages(mContext, updatedContacts);
|
||||
|
||||
// This is a demo of how you can add stream items for contacts on
|
||||
// the client. This probably won't apply to
|
||||
// 2-way contact sync providers - it's more likely that one-way
|
||||
// sync providers (IM clients, social networking apps, etc) would
|
||||
// use this feature. This is only supported in ICS MR1 or above.
|
||||
|
||||
if (Build.VERSION.SDK_INT >=
|
||||
Build.VERSION_CODES.ICE_CREAM_SANDWICH_MR1) {
|
||||
ContactManager.addStreamItems(mContext, updatedContacts,
|
||||
account.name, account.type);
|
||||
}
|
||||
|
||||
// Save off the new sync marker. On our next sync, we only want to receive
|
||||
// contacts that have changed since this sync...
|
||||
setServerSyncMarker(account, newSyncState);
|
||||
|
||||
Reference in New Issue
Block a user