author | zautrix <zautrix> | 2004-10-07 12:19:25 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-10-07 12:19:25 (UTC) |
commit | 826dc960353e47a60aba13916189c45ef3392c1e (patch) (side-by-side diff) | |
tree | 52ef4058d7a1fa8d77e678391ed9165009634182 /kabc/addressbook.cpp | |
parent | 43c82cc5393522d2c34f34a4339cb6a1d1c6c555 (diff) | |
download | kdepimpi-826dc960353e47a60aba13916189c45ef3392c1e.zip kdepimpi-826dc960353e47a60aba13916189c45ef3392c1e.tar.gz kdepimpi-826dc960353e47a60aba13916189c45ef3392c1e.tar.bz2 |
sync fixes
-rw-r--r-- | kabc/addressbook.cpp | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/kabc/addressbook.cpp b/kabc/addressbook.cpp index 295cf03..03a86f9 100644 --- a/kabc/addressbook.cpp +++ b/kabc/addressbook.cpp @@ -393,49 +393,48 @@ void AddressBook::export2File( QString fileName ) if ( !(*it).IDStr().isEmpty() ) { (*it).insertCustom( "KADDRESSBOOK", "X-ExternalID", (*it).IDStr() ); } KABC::VCardConverter converter; QString vcard; //Resource *resource() const; converter.addresseeToVCard( *it, vcard, version ); t << vcard << "\r\n"; } outFile.close(); } void AddressBook::importFromFile( QString fileName ) { KABC::Addressee::List list; QFile file( fileName ); file.open( IO_ReadOnly ); QByteArray rawData = file.readAll(); file.close(); QString data = QString::fromUtf8( rawData.data(), rawData.size() + 1 ); KABC::VCardTool tool; list = tool.parseVCards( data ); - KABC::Addressee::List::Iterator it; for ( it = list.begin(); it != list.end(); ++it ) { (*it).setResource( 0 ); insertAddressee( (*it), false, true ); } } bool AddressBook::saveAB() { bool ok = true; deleteRemovedAddressees(); Iterator ait; for ( ait = begin(); ait != end(); ++ait ) { if ( !(*ait).IDStr().isEmpty() ) { (*ait).insertCustom( "KADDRESSBOOK", "X-ExternalID", (*ait).IDStr() ); } } KRES::Manager<Resource>::ActiveIterator it; KRES::Manager<Resource> *manager = d->mManager; for ( it = manager->activeBegin(); it != manager->activeEnd(); ++it ) { if ( !(*it)->readOnly() && (*it)->isOpen() ) { Ticket *ticket = requestSaveTicket( *it ); |