summaryrefslogtreecommitdiffabout
path: root/kaddressbook/kabcore.cpp
Side-by-side diff
Diffstat (limited to 'kaddressbook/kabcore.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--kaddressbook/kabcore.cpp14
1 files changed, 9 insertions, 5 deletions
diff --git a/kaddressbook/kabcore.cpp b/kaddressbook/kabcore.cpp
index bdc5bd8..c75b4bc 100644
--- a/kaddressbook/kabcore.cpp
+++ b/kaddressbook/kabcore.cpp
@@ -2638,3 +2638,3 @@ bool KABCore::synchronizeAddressbooks( KABC::AddressBook* local, KABC::AddressBo
return false;
- if ( take == 1 ) {// take local
+ if ( take == 1 ) {// take local **********************
if ( mGlobalSyncMode == SYNC_MODE_EXTERNAL ) {
@@ -2663,3 +2663,3 @@ bool KABCore::synchronizeAddressbooks( KABC::AddressBook* local, KABC::AddressBo
++changedRemote;
- } else { // take == 2 take remote
+ } else { // take == 2 take remote **********************
if ( mGlobalSyncMode == SYNC_MODE_EXTERNAL ) {
@@ -2682,3 +2682,3 @@ bool KABCore::synchronizeAddressbooks( KABC::AddressBook* local, KABC::AddressBo
}
- } else { // no conflict
+ } else { // no conflict ********** add or delete remote
if ( mGlobalSyncMode == SYNC_MODE_EXTERNAL ) {
@@ -2692,3 +2692,6 @@ bool KABCore::synchronizeAddressbooks( KABC::AddressBook* local, KABC::AddressBo
remote->insertAddressee( inR, false );
- inL = inR;
+ inL = inR;
+ inL.setIDStr( ":" );
+ inL.setCsum( mCurrentSyncDevice, inR.getCsum(mCurrentSyncDevice) );
+ inL.setID( mCurrentSyncDevice, inR.getID(mCurrentSyncDevice) );
inL.setResource( 0 );
@@ -2734,3 +2737,3 @@ bool KABCore::synchronizeAddressbooks( KABC::AddressBook* local, KABC::AddressBo
inR = remote->findByUid( uid );
- if ( inR.isEmpty() ) {
+ if ( inR.isEmpty() ) { / no conflict ********** add or delete local
if ( mGlobalSyncMode == SYNC_MODE_EXTERNAL ) {
@@ -2763,2 +2766,3 @@ bool KABCore::synchronizeAddressbooks( KABC::AddressBook* local, KABC::AddressBo
inR = inL;
+ inR.setIDStr( ":" );
inR.setResource( 0 );