Summary: | dragging addresses from address book into kmail composer address fields pastes a vCardJu | ||
---|---|---|---|
Product: | kab3 | Reporter: | Oded Arbel <oded> |
Component: | general | Assignee: | Tobias Koenig <tokoe> |
Status: | RESOLVED UNMAINTAINED | ||
Severity: | normal | ||
Priority: | NOR | ||
Version: | 3.1 | ||
Target Milestone: | --- | ||
Platform: | unspecified | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: |
Description
Oded Arbel
2003-11-17 13:05:41 UTC
Subject: kdepim/kaddressbook CVS commit by tokoe: Use the email addresses in a QTextDrag and not the vCards. That fixes bug #68417. CCMAIL:68417-done@bugs.kde.org M +11 -0 addresseeutil.cpp 1.11 M +16 -11 addresseeutil.h 1.5 M +1 -1 viewmanager.cpp 1.99 --- kdepim/kaddressbook/addresseeutil.cpp #1.10:1.11 @@ -43,2 +43,13 @@ KABC::Addressee::List AddresseeUtil::cli return tool.parseVCards( data ); } + +QString AddresseeUtil::addresseesToEmails( const KABC::Addressee::List &addrList ) +{ + QStringList emails; + + KABC::Addressee::List::ConstIterator it; + for ( it = addrList.begin(); it != addrList.end(); ++it ) + emails.append( (*it).fullEmail() ); + + return emails.join( "," ); +} --- kdepim/kaddressbook/addresseeutil.h #1.4:1.5 @@ -54,4 +54,9 @@ class AddresseeUtil static KABC::Addressee::List clipboardToAddressees( const QString &clipboard ); + /** + Converts the list of addressee objects into a list of email addresses. + */ + static QString addresseesToEmails( const KABC::Addressee::List &addrList ); + private: AddresseeUtil() {} --- kdepim/kaddressbook/viewmanager.cpp #1.98:1.99 @@ -422,5 +422,5 @@ void ViewManager::startDrag() KMultipleDrag *drag = new KMultipleDrag( this ); - drag->addDragObject( new QTextDrag( AddresseeUtil::addresseesToClipboard( addrList ), this ) ); + drag->addDragObject( new QTextDrag( AddresseeUtil::addresseesToEmails( addrList ), this ) ); KABC::VCardTool tool; The development of the old KAddressBook will be discontinued for KDE 4.4. Since the new application has the same name, but a completly new code base we close all bug reports against the old version and ask the submitters to resend there reports against the new product. |