summaryrefslogtreecommitdiffabout
Side-by-side diff
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--kabc/addressbook.cpp9
-rw-r--r--kaddressbook/kabcore.cpp3
2 files changed, 10 insertions, 2 deletions
diff --git a/kabc/addressbook.cpp b/kabc/addressbook.cpp
index 3ec0795..d03dea3 100644
--- a/kabc/addressbook.cpp
+++ b/kabc/addressbook.cpp
@@ -459,10 +459,15 @@ void AddressBook::insertAddressee( const Addressee &a, bool setRev )
if ( (*it).resource() == 0 )
(*it).setResource( standardResource() );
if ( changed ) {
- if ( setRev )
- (*it).setRevision( QDateTime::currentDateTime() );
+ if ( setRev ) {
+ // get rid of micro seconds
+ QDateTime dt = QDateTime::currentDateTime();
+ QTime t = dt.time();
+ dt.setTime( QTime (t.hour (), t.minute (), t.second () ) );
+ (*it).setRevision( dt );
+ }
(*it).setChanged( true );
}
return;
diff --git a/kaddressbook/kabcore.cpp b/kaddressbook/kabcore.cpp
index 226d5e4..215ce83 100644
--- a/kaddressbook/kabcore.cpp
+++ b/kaddressbook/kabcore.cpp
@@ -2901,8 +2901,11 @@ bool KABCore::synchronizeAddressbooks( KABC::AddressBook* local, KABC::AddressBo
bar.hide();
mLastAddressbookSync = QDateTime::currentDateTime().addSecs( 1 );
+ // get rid of micro seconds
+ QTime t = mLastAddressbookSync.time();
+ mLastAddressbookSync.setTime( QTime (t.hour (), t.minute (), t.second () ) );
addresseeLSync.setRevision( mLastAddressbookSync );
addresseeRSync.setRevision( mLastAddressbookSync );
addresseeRSync.setGivenName( i18n("Remote from: ")+mCurrentSyncName ) ;
addresseeLSync.setGivenName(i18n("Local from: ") + mCurrentSyncName );