summaryrefslogtreecommitdiffabout
path: root/kabc/addressbook.cpp
Unidiff
Diffstat (limited to 'kabc/addressbook.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--kabc/addressbook.cpp19
1 files changed, 15 insertions, 4 deletions
diff --git a/kabc/addressbook.cpp b/kabc/addressbook.cpp
index 9b196b5..5774c36 100644
--- a/kabc/addressbook.cpp
+++ b/kabc/addressbook.cpp
@@ -876,2 +876,9 @@ void AddressBook::removeSyncAddressees( bool removeDeleted )
876 //qDebug("skipping %s ",(*it).uid().latin1() ); 876 //qDebug("skipping %s ",(*it).uid().latin1() );
877 if ( removeDeleted ) {
878 // we have no postprocessing in the resource, we have to do it here
879 // we have to compute csum for all, because it could be the first sync
880 (*it).setTempSyncStat( SYNC_TEMPSTATE_NEW_CSUM );
881
882
883 }
877 ++it; 884 ++it;
@@ -919,3 +926,3 @@ void AddressBook::preExternSync( AddressBook* aBook, const QString& csd , bool i
919} 926}
920void AddressBook::postExternSync( AddressBook* aBook , const QString& csd) 927void AddressBook::postExternSync( AddressBook* aBook , const QString& csd, bool setID)
921{ 928{
@@ -924,3 +931,3 @@ void AddressBook::postExternSync( AddressBook* aBook , const QString& csd)
924 for ( it = begin(); it != end(); ++it ) { 931 for ( it = begin(); it != end(); ++it ) {
925 // qDebug("check uid %s ", (*it).uid().latin1() ); 932 //qDebug("check uid %s ", (*it).uid().latin1() );
926 if ( (*it).tempSyncStat() == SYNC_TEMPSTATE_NEW_ID || 933 if ( (*it).tempSyncStat() == SYNC_TEMPSTATE_NEW_ID ||
@@ -931,5 +938,9 @@ void AddressBook::postExternSync( AddressBook* aBook , const QString& csd)
931 } else { 938 } else {
939 (*it).setIDStr(":");
932 (*it).computeCsum( csd ); 940 (*it).computeCsum( csd );
933 if ( (*it).tempSyncStat() == SYNC_TEMPSTATE_NEW_ID ) 941 if ( setID ) {
934 ad.setID( csd, (*it).externalUID() ); 942 if ( (*it).tempSyncStat() == SYNC_TEMPSTATE_NEW_ID )
943 ad.setID( csd, (*it).externalUID() );
944 } else
945 ad.setID( csd, "_" );
935 ad.setCsum( csd, (*it).getCsum( csd ) ); 946 ad.setCsum( csd, (*it).getCsum( csd ) );