-rw-r--r-- | kabc/addressbook.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/kabc/addressbook.cpp b/kabc/addressbook.cpp index 6e8d027..3ec0795 100644 --- a/kabc/addressbook.cpp +++ b/kabc/addressbook.cpp @@ -440,31 +440,32 @@ Ticket *AddressBook::requestSaveTicket( Resource *resource ) else return (*it)->requestSaveTicket(); } } return 0; } -void AddressBook::insertAddressee( const Addressee &a ) +void AddressBook::insertAddressee( const Addressee &a, bool setRev ) { Addressee::List::Iterator it; for ( it = d->mAddressees.begin(); it != d->mAddressees.end(); ++it ) { if ( a.uid() == (*it).uid() ) { bool changed = false; Addressee addr = a; if ( addr != (*it) ) changed = true; (*it) = a; if ( (*it).resource() == 0 ) (*it).setResource( standardResource() ); if ( changed ) { + if ( setRev ) (*it).setRevision( QDateTime::currentDateTime() ); (*it).setChanged( true ); } return; } } d->mAddressees.append( a ); |