author | zautrix <zautrix> | 2005-04-04 11:29:55 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-04-04 11:29:55 (UTC) |
commit | 23db4aa99cb7a5feb540b6be578efaee8ec6ef80 (patch) (side-by-side diff) | |
tree | f60d08e53dc09cf8a9ca901697797de9cf5dc669 /kaddressbook | |
parent | 69a388bdef8d4a31063f983735d2b7d25775f3cf (diff) | |
download | kdepimpi-23db4aa99cb7a5feb540b6be578efaee8ec6ef80.zip kdepimpi-23db4aa99cb7a5feb540b6be578efaee8ec6ef80.tar.gz kdepimpi-23db4aa99cb7a5feb540b6be578efaee8ec6ef80.tar.bz2 |
sync fixes
-rw-r--r-- | kaddressbook/kabcore.cpp | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/kaddressbook/kabcore.cpp b/kaddressbook/kabcore.cpp index 20b107e..fa9f130 100644 --- a/kaddressbook/kabcore.cpp +++ b/kaddressbook/kabcore.cpp @@ -2440,6 +2440,10 @@ void KABCore::setFormattedName() int count = 0; KABC::AddressBook::Iterator it; + bool modified = false; for ( it = mAddressBook->begin(); it != mAddressBook->end(); ++it ) { if ( (*it).tagged() ) { + if ( (*it).uid().left( 2 ) == "la" ) + if ( (*it).uid().left( 19 ) == QString("last-syncAddressee-") ) + continue; ++count; if ( count %10 == 0 ) @@ -2459,12 +2463,19 @@ void KABCore::setFormattedName() fName = (*it).organization(); (*it).setFormattedName( fName ); + (*it).setChanged( true ); + modified = true; + (*it).setRevision( QDateTime::currentDateTime() ); } } message(i18n("Refreshing view...") ); qApp->processEvents(); - mViewManager->refreshView( "" ); + if ( modified ) + setModified( true ); Addressee add; mDetails->setAddressee( add ); - message(i18n("Setting formatted name completed!") ); + if ( count == 0 ) + message(i18n("No contact changed!") ); + else + message(i18n("%1 contacts changed!").arg( count ) ); } |