Bug 121130 - Paste as attachment does not work for multiple files in KMail
Summary: Paste as attachment does not work for multiple files in KMail
Status: RESOLVED FIXED
Alias: None
Product: kmail
Classification: Applications
Component: composer (show other bugs)
Version: 1.9
Platform: unspecified Linux
: NOR normal
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
: 131757 (view as bug list)
Depends on:
Blocks:
 
Reported: 2006-02-01 08:16 UTC by A T Somers
Modified: 2007-11-12 12:41 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description A T Somers 2006-02-01 08:16:42 UTC
Version:           1.9 (using KDE 3.5.0, Gentoo)
Compiler:          gcc version 3.3.6 (Gentoo 3.3.6, ssp-3.3.6-1.0, pie-8.7.8)
OS:                Linux (i686) release 2.6.14-gentoo-r4

When selecting more than one file in Konqueror, copying them (CTRL-C) and trying to attach them "paste" in the composer window for an email using "Paste as Attachment", an error pops up complaining about the non-existence of the URL. The error shows both files, and I guess the URLs got combined somehow?
Pasting a single file at a time works.

I expected to be able to paste more than one file as attachment in one go.
Comment 1 Philip Rodrigues 2006-02-01 16:20:51 UTC
Confirmed with r496940. Konq copies the URLs as "file:///path/to/file1 file:///path/to/file2", which on its own isn't a file that exists. I don't know how kmail should handle this. Perhaps the fix needs to happen in konq?
Comment 2 Philip Rodrigues 2006-08-03 20:21:07 UTC
*** Bug 131757 has been marked as a duplicate of this bug. ***
Comment 3 Philip Rodrigues 2006-08-03 20:21:45 UTC
A note from Stefan Gehn in bug 131757:

Developer note: 
 The problem is in KMComposeWin::slotPasteAsAttachment() which calls KURL constructor with the clipboard contents. Checking for \n and splitting the text accordingly could help but I'm not sure if that's the best thing to do. Also I'm puzzled how url.isValid() can return true for an url that contains a newline and another protocol definition in the middle of the string. 
Comment 4 A T Somers 2006-10-28 19:20:55 UTC
Still the case with 3.5.5
Comment 5 Bram Schoenmakers 2007-03-10 21:45:24 UTC
Please note that drag 'n drop for multiple files still works.
Comment 6 Edwin Schepers 2007-09-12 20:31:45 UTC
SVN commit 711755 by eschepers:

menuitem 'Paste as attachment' now works for multiple files
BUG: 121130


 M  +7 -3      kmcomposewin.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=711755
Comment 7 A T Somers 2007-09-13 09:24:24 UTC
Excellent! Thanks a lot! 
Comment 8 p 2007-11-11 06:16:58 UTC
Just installed KDE 3.5.8 on Suse 10.2. Still the same issue. With which release should we see the bug fix?
Comment 9 Jonathan Marten 2007-11-12 12:41:36 UTC
Regarding comment #8: In KDE 4, unless someone backports the fix to 3.5 branch.