Closed Bug 377621 Opened 17 years ago Closed 1 year ago

[Thunderbird] Drag and Drop attachments to desktop or folders doesn't work

Categories

(Core :: Widget: Gtk, defect, P2)

x86
Linux
defect

Tracking

()

RESOLVED FIXED
96 Branch
Tracking Status
firefox96 --- fixed
firefox108 --- fixed

People

(Reporter: rabo69, Assigned: stransky)

References

(Blocks 1 open bug)

Details

(Whiteboard: tpi:-)

Attachments

(5 files, 12 obsolete files)

721 bytes, patch
Details | Diff | Splinter Review
18.20 KB, patch
Details | Diff | Splinter Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
User-Agent:       Mozilla/5.0 (X11; U; Linux i686; de; rv:1.8.1.3) Gecko/20060601 Firefox/2.0.0.3 (Ubuntu-edgy)
Build Identifier: Thunderbird Version 2.0.0.0 (20070326) and also Version 1.5.0.10 (20070306) 

If you try to move a attachment via Drag and Drop outside Thunderbird to the desktop or a folder on the PC the drag and drop cursor symbols shows up correctly but no file will be created/moved to this place (This works fine under windows)

(The error shows under Gnome Desktop Ubuntu EdgyEft 6.10 and also under Feisty Fawn 7.04)

Reproducible: Always

Steps to Reproduce:
1. drag an email attachment
2 [review]. move the cursor to desktop (press shift or control or nothing - same thing)
3. release mouse button
Actual Results:  
no file will be created/moved to the drop place

Expected Results:  
the attachment should moved/copied to the drop place (in windows this works fine)
I can confirm this behavior on my machine  on Fedora with KDE.
it ask to create file, but actually has no content from attachment
confirmed on fedora fc 6 with thunderbird 2 release build.
Status: UNCONFIRMED → NEW
Ever confirmed: true
with trunk build thunderbird-3.0a1.en-US.linux-i686, bug can also be reproduced
Similar problem with OS WinXP as well. If you drag the attachment to the desktop you have to keep the left mouse button pressed for some seconds so the attachment is "loaded" (you see a progress bar). Then you can release the button and the attachment is successfull copied. Otherwise (without waiting) an errormessage shows up ("file in use"). You can work with this unconvenience but it is unexpected, not state of the art and contradicts usability a lot (because it took me quite a while to find out).
If you can confirm this behaviour please extend this bug to OS WinXP as well.
bug still exists in new TB 2.0.0.4
bug still exists in TB 2.0.0.6
Assignee: mscott → nobody
Hej,

the problem is that thunderbird doesn't provide a text/uri-list flavour that
could be evaluated by the desktop environment to copy the attachment somewhere
else.

One idea would be to save the attachment to a temporary file and pass the url
of that file as a test/uri-list flavour in the drag operation.
To make that feature work for all platforms, a java script based implementation
would be preferred. So can somebody point me to the place in the mozilla sources
where the drag for attachments is started?
 mailnews/base/resources/content/msgHdrOverlay.js:attachmentAreaDNDObserver
sounds promising, however that method seems not to be called when I try to
drag an attachment from the message view.

BTW, when I drag the attachment to the desktop, the JS error console shows the following message:

Error: [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsITransferable.getTransferData]"  nsresult: "0x80004005 (NS_ERROR_FAILURE)"  location: "JS frame :: chrome://messenger/content/msgHdrViewOverlay.js :: anonymous :: line 1627"  data: no]
Source File: chrome://messenger/content/msgHdrViewOverlay.js
Line: 1627

It seems like the 'application/moz-file-promise-url' flavour is missing...
Can somebody enlighten me what that flavour is for and why it could be missing?

Ciao,
Tobias
Hej,

this patch allows drag&drop of attachments to the desktop by saving the requested attachment to a temporary file and passing the URL of that file in the drag object. The patch has still two issues: 1) '/tmp' is hard coded... It seems nsIFileUtilities::getTempDirPath() could help here, but how do I instantiate such a component?
2) The name of the temporary file is the same as stored in the attachment, however as it's a temporary file, it should have a unique name (like returned by mktemp(3) under Unix). nsIFileUtilities::newTempFileName() looks promising, but could it be that there is no implementation for that method?
Attachment #328330 - Flags: review?(dmose)
Assignee: nobody → tokoe
See similar Win XP bug here:
https://bugzilla.mozilla.org/show_bug.cgi?id=384590

Bug only occurs, when attachment is "large" (> 2MB).
Summary: Drag and Drop to desktop or folders doesn't work → Drag and Drop attachments to desktop or folders doesn't work
Ubuntu has this bug in bug tracker the link for it is
https://bugs.launchpad.net/ubuntu/+source/thunderbird/+bug/151162
Hej,

any news on that issue? Is the patch ok for review/superreview?

Ciao,
Tobias
Hej,

the new patch uses directory-service to retrieve the temporary directory instead of hardcoding "/tmp".

Ciao,
Tobias
Attachment #328330 - Attachment is obsolete: true
Attachment #340309 - Flags: review?(dmose)
Attachment #328330 - Flags: review?(dmose)
Two comments:
1. The patch need to be updated to apply the trunk
2. I still can't DnD my attachment to my desktop
Attachment #340309 - Flags: review?(dmose) → review?(mkmelin+mozilla)
Comment on attachment 340309 [details] [diff] [review]
Use the directory-service for temporary file now

dmose isn't building on linux much these days, so switching review to magnus.
Attached patch adapt to HEAD (obsolete) — Splinter Review
Adapted to HEAD. Could somebody do a review soon, please?
I really don't want to update the patch here forever :(
Attachment #340309 - Attachment is obsolete: true
Attachment #365417 - Flags: superreview?(mkmelin+mozilla)
Attachment #365417 - Flags: review?(mkmelin+mozilla)
Attachment #340309 - Flags: review?(mkmelin+mozilla)
I hope to get to this later this week, sorry about the delay.
Attachment #365417 - Attachment is obsolete: true
Attachment #365417 - Flags: superreview?(mkmelin+mozilla)
Attachment #365417 - Flags: review?(mkmelin+mozilla)
Comment on attachment 365417 [details] [diff] [review]
adapt to HEAD

Mozilla is using hg now, so for future ref, please make patches against hg tip (cvs HEAD is getting old). 

The patch doesn't apply cleanly to hg tip, but I've unbitrotted and played with it a bit. Will attach that in a moment.

(no sr needed for mail/ only changes, and I'm not a super-reviewer)
Attached patch proposed fix (unbitrotted) (obsolete) — Splinter Review
Unbitrotted, and creating the file:// url in a safer way.

This patch works, but it's a bit ugly.

Windows doesn't need to do it this way, so I'm thinking the "proper" fix is probably somewhere in the gtk drag service

http://mxr.mozilla.org/comm-central/source/mozilla/widget/src/windows/nsDragService.cpp#559
http://mxr.mozilla.org/comm-central/source/mozilla/widget/src/gtk2/nsDragService.cpp

What do you think?
E.g. bug 267426 may be of interest, though it's windows only afaikt.
Moving from General -> MWFE, I was torn between MWFE and Message Reader UI, not so sure, feel free to change though.

We'd need litmus tests to cover this - I'm not sure if MozMill can do DnD out to a non-XUL app (i.e. to Desktop).
Component: General → Mail Window Front End
QA Contact: general → front-end
Version: unspecified → Trunk
(In reply to comment #20)
 
> We'd need litmus tests to cover this - I'm not sure if MozMill can do DnD out
> to a non-XUL app (i.e. to Desktop).

Good point. Do you feel about adding them ?
Flags: in-litmus?
(In reply to comment #21)
> (In reply to comment #20)
> 
> > We'd need litmus tests to cover this - I'm not sure if MozMill can do DnD out
> > to a non-XUL app (i.e. to Desktop).
> 
> Good point. Do you feel about adding them ?

Not at the moment - this is a Linux-only bug AFAICT (Windows is covered somewhere else), and I touch Linux only barely. Mac doesn't seem to have this issue (but has issues with DnD of multiple-selected attachments, but that's another thing altogether).
(In reply to comment #18)
> Unbitrotted, and creating the file:// url in a safer way.
> 
> This patch works, but it's a bit ugly.
Thanks for the update!

> Windows doesn't need to do it this way, so I'm thinking the "proper" fix is
> probably somewhere in the gtk drag service
> 
> http://mxr.mozilla.org/comm-central/source/mozilla/widget/src/windows/nsDragService.cpp#559
> http://mxr.mozilla.org/comm-central/source/mozilla/widget/src/gtk2/nsDragService.cpp
Hmm, but how can I create such a temporary file inside the drag service implementation?

I have only a mailbox:// URL to the attachment there... what component can
I use to extract the attachment from the file, pointed by the mailbox:// URL, and store it in a temporary file?

Or is there another way to retrieve the attachment data somehow? /me is still missing the overview how these things work together :(

Ciao,
Tobias
Sorry, I don't think i'll be able to help much, and it might not be easy at all... First step is probably to figure out what windows does, and if you can do something similar on *nix.
Windows accepts native com interface iStream for data and our side fills that in. Here's a reference to the object created for windows dnd API compliance.

http://mxr.mozilla.org/comm-central/source/mozilla/widget/src/windows/nsDataObj.cpp#910

I can't do unix but writing the temp file for O/S use should be similiar backend IMO
Attached patch fixes url -- needs testing (obsolete) — Splinter Review
This is a test patch for unix build.  I don't have unix to test so please someone on cc test this.

The url passed as flavour data has 2 '&filename='.  This may be a problem with unix DND code and may be the problem here.
the filename is unescaped so it should not have spaces or non-alpha char, see
bug 485514
(In reply to comment #26)
> This is a test patch for unix build.  I don't have unix to test so please
> someone on cc test this.

Tested briefly on my build (which is a little old but I don't think attachment code has changed much). Doesn't work. + cursor appears, appears to start moving on drop, but complains it couldn't find the file to move. Nothing gets dropped.
> (In reply to comment #26)
> Tested briefly on my build (which is a little old but I don't think attachment
> code has changed much). Doesn't work. + cursor appears, appears to start moving
> on drop, but complains it couldn't find the file to move. Nothing gets dropped.

would you or anyone with a Linux debug build post a log of nsDragService
export NSPR_LOG_MODULES=nsDragService:5
export NSPR_LOG_FILE=bug377621.log
could someone try this fix of the URL flavor revision. The other patch was on seamonkey not TB so it would not have any effect.
Attachment #371844 - Attachment is obsolete: true
in windows the only flavours required for file drop are:
-text/x-moz-url 
-application/x-moz-file-promise-url",
-application/x-moz-file-promise, with 'null' for data.
if the x-moz-file-promise is omitted then an internet-type shortcut is created.
Tobias
To get this to do backend like windows create a stream from the URI then save the stream as the temp file then send it to the desktop in GTK manner. There may be other code to create a file directly from the URI.

Creating the stream is mozilla common code and the windows-specific backend code does it here which :
http://mxr.mozilla.org/comm-central/source/mozilla/widget/src/windows/nsDataObj.cpp#122

That will get windows and GTK to work and hopefully Mac works too, if not we need to do the same there.
This gives us a clean frontend which we can use to DND messages to the desktop.
Maybe Michael can mek sense of this.
This patch implements drag&drop from thunderbird to the Linux desktop (or file manager) by changing code in widgets/src/gtk2 only.
It makes use of the kFilePromise feature to trigger the mail component to save the attachment to a temporary file whenever the text/uri-list flavor is requested on a drag&drop operation. The url of the temporary file is passed as flavor data then...
Could somebody comment on the code, please? I guess the string conversion can be done easier...
Don't you need to use CreateUnique to ensure that the temp file name doesn't clobber something else?

Instead of indenting a lot, use early exits and a helper function if necessary.

You're assuming the URI is UTF-8, I'm not sure if that's right...
https://bugzilla.mozilla.org/attachment.cgi?id=374754&action=diff#a/widget/src/gtk2/nsDragService.cpp_sec4

I may not read this correct but does this section make the transfer rely on the text/x-moz-url?

As a request to roc, I would think since a file transfer, like doing this attachment, will never create a shortcut url then this should not depend on it. So we should set it up where only the application/x-moz-file-promise-xx types are needed.
In the front end, msgHdrViewOverlay.js, we are still mixing the old technology of d&d with the new one. Going from TB2 to TB3 windows no longer uses the nsFlavorDataProvider implementation. In fact you can substituete null for the data and completely remove the interface here http://mxr.mozilla.org/comm-central/source/mail/base/content/msgHdrViewOverlay.js#1928 and it still works.

Windows gets the url from x-moz-file-promise-url and creates a stream which is sent to windows.  GTK and other platforms should either create a stream or create the temp file as suits the platform and we should remove the nsFlavorDataProvider implementation in msgHdrViewOverlay.js.

If we don't then we will have the front end doing platform specific stuff without anyway to tell without digging into the backend differences. The least we should do is comment the .js file what is being done.

Windows b/e does all this with essentially the one line of code here.

http://mxr.mozilla.org/comm-central/source/mozilla/widget/src/windows/nsDataObj.cpp#125

...then windows native reads the stream.  Here in GTK we can write it to the temp file and pass it back in the uri-list.

Also if we stick with this front end way we need to do the same messy stuff in bug 227305.

Or
We can scrap windows method and go back to this implementation for windows. In that way we can drag a txt file to word, or a .cpp file to visual studio or a doc file to word. Which can't be done with the stream. But that's not a big deal, we can always add x-moz-file flavour to tell windows to create a temp file and stick with the stream.
I like what Phil mentioned about going back to one implementation. Does this have an ETA? I have moved to Thunderbird (from KMail) and have since moved to GNOME (from KDE) and find this frustrating, since d&d works perfectly fine on windows but not on *nix.
This will drag and drop attachments from IMAP or local folders to windows XP operating system. As one may notice, it is minimal front end requirements. Mac and GTK should conform to these flavors, except the x-moz-url which may be eliminated in a future bug.
Lets set this to mac o/s as well for testing and get a backend fix for GTK.
I am assuming if this gets reviewed and cleared by roc then Tobias can do the GTK stuff.
Attachment #378778 - Flags: review?(roc)
The new version uses streams instead of kFilePromiseUrl. However there are some outstanding issues (temporary files are not removed, too many files generated) that needs fixing, so this patch is a working proof of concept ;)
Attachment #374754 - Attachment is obsolete: true
I assume the patch in comment #40 is not supposed to be checked in until Mac and GTK drag-drop implementations support sending URL contents to streams.

But I'm not really sure if this is the right way to go. Neil Deakin is the best person for this, I think.
Another option that may not be cleaner but clearer. In this front end, write to a temp file and transfer it as a 'move' with x-moz-file. Then we may be able to drag attachments to text editors or pdf readers etc.
If x-moz-file transfers aren't working then those are something that probably should be fixed in 1.9.1 whereas the moz-file-promise ones need looking into.
I'm not sure what the need for the x-moz-file-promise-xxx flavors originated that separates them from a simple temp file transfer, but maybe for TB3 we should avoid them altogether until they are revamped for use the same way in all platforms.
Attachment #378778 - Flags: review?(roc)
This version of the patch should be functional complete. It creates only
one temporary file for each drag&drop operation and removes all temporary
files at the end, when thunderbird is closed.

Could some of the core developers do a review (coding style, string conversion etc.), please?
Attachment #379435 - Attachment is obsolete: true
Comment on attachment 379666 [details] [diff] [review]
Drag&Drop support by widget/gtk2 code with streams

You have to specifically ask review to someone to get a review. I don't know if Robert is the correct person to review this (probably not), but hopefully he can point to someone who is more suited to review the patch.
Attachment #379666 - Flags: review?(roc)
What is this patch trying to accomplish? If you're expecting the operating system to handle the data as a file, you should be using a file promise or file type. When using the url type, it is up to destination application to retrieve it, we shouldn't be creating it for them.
(In reply to comment #46)
> What is this patch trying to accomplish? If you're expecting the operating
> system to handle the data as a file, you should be using a file promise or file
> type.
That doesn't work... und Linux the desktop/filemanager expects that the file is passed as text/uri-list flavour and the desktop/filemanager is responsible to copy
the file to the correct destination.

> When using the url type, it is up to destination application to retrieve
> it, we shouldn't be creating it for them.
How should the destination application access the internal data of thunderbird
if it gets only a mailbox:// url passed? ;)
Now, we have to use the defined standards here...

Ciao,
Tobias
Per comment #46, in the backend if it receives the filepromise flavours it can still convert the data to the text/uri-list and do its thing.

In windows the x-moz-url flavor creates a link file of 'internet shortcut' type. If this is correct other o/s should do the same.

If we use the x-moz-file type then the front ends need to do the work outputting to a temp file and passing data as nsIFile per spec. That would facilitate drag and drop to other apps which can receive temp files but not streamed data. The temp file can still be deleted and the other app notes it and gives its user the option to save it.

Ideally, we should use the best of both worlds. This is data not a file and should use filepromise but in backend the data should be offered as both and either streamed or a file made as requested by the target.
Comment on attachment 379666 [details] [diff] [review]
Drag&Drop support by widget/gtk2 code with streams

>+    nsCOMPtr<nsISupports> data;
>+    rv = aTransferable->GetTransferData(kURLMime,
>+                                        

to comply with comment #46 can we make this kFilePromiseURLMime

>+        nsPrimitiveHelpers::CreateDataFromPrimitive(kURLMime,
>+                                                    data,
>+                                                    

and here

the url should be in the data for x-moz-file-promise-url


>+        if (strcmp(mimeFlavor, gTextUriListType) == 0 && !mTempFileCreated) {
>+            nsCOMPtr<nsIFile> tmpDir;

a check for kFilePromiseURLMime needed
This version of the patch uses kFilePromiseURLMime again as suggested by Phil in #49.
Attachment #379666 - Attachment is obsolete: true
Attachment #386466 - Flags: review?
Attachment #379666 - Flags: review?(roc)
Comment on attachment 386466 [details] [diff] [review]
Drag&Drop support by widget/gtk2 code with streams

I think roc is the reviewer name to set here.
Here's my notes from what I can compare to windows version.  I don't have linux to check further than that.

>+    mTempFileCreated = PR_FALSE;

don't quite follow its need, but that may be me.

>+nsresult GetAttachmentDetails(nsITransferable * aTransferable, nsIURI 

maybe use 'GetDownloadDetails' like windows or similiar generic name. This can be used for messages, files, or other data besides attachments.

>+                        // check if text/x-moz-url is supported.

did you mean application/x-moz-file-promise-url

>+        // The desktop or file manager expects for drags of attachments the
>+        // text/uri-list flavor set to a temporary file that contains the
>+        // attachment.
>+        // We open a stream on the mailbox:// url here and save the content
>+        // to file:///tmp/dnd_attachment/<attachmentname> and pass this url
>+        // as text/uri-list flavor.

again, attachments are only one use. 'promise-file' or 'promise-file data' for clarity, and mailbox:// could be other handler <protocol>://

>+            // build the file:///tmp/dnd_attachment URL
>+            tmpDir->Append(NS_LITERAL_STRING("dnd_attachment"));
>+            tmpDir->CreateUnique(nsIFile::DIRECTORY_TYPE, 0775);

don't know how much 'naming' needs to be added to file name for linux use or obfuscation but I assume CreateUnique would be enough. Again 'attachment' should be more generic if needed at all.


>+            mTempFileCreated = PR_TRUE;
>+            mTemporaryFiles.AppendObject(tempFile);

again mTempFileCreated is set but can't see its use. If it is necessary it may be better set after the outputstream succeeds.

repeating! I'm not a reviewer. my comments are only notes. Use at your or reviewer's discretion.
Tobias: you need to ask review from a specific person. (Set the review flag to roc@ocallahan.org)

You may want to update the patch according to comment 51 first though.
(In reply to comment #51)
> 
> >+    mTempFileCreated = PR_FALSE;
> 
> don't quite follow its need, but that may be me.

to clear this point, Tobias indicated that GTK (like windows) tends to call the file creation functions more than once so this prevents multiple copies of the temp file.
Sorry for the late reply, exams at university...

The new patch addresses all issues (references to 'attachment', outdated comments etc.) Phil mentioned in previous comment.
Attachment #386466 - Attachment is obsolete: true
Attachment #390806 - Flags: review?(roc)
Attachment #386466 - Flags: review?
Comment on attachment 390806 [details] [diff] [review]
New version that removes all references to attachments

I'll hand this off to our GTK2 superhero
Attachment #390806 - Flags: review?(roc) → review?(mozbugz)
Attachment #365876 - Attachment is obsolete: true
Comment on attachment 378778 [details] [diff] [review]
this is dnd requirements for windows XP

I assume that comment 46 effectively made this obselete.
Attachment #378778 - Attachment is obsolete: true
Comment on attachment 390806 [details] [diff] [review]
New version that removes all references to attachments

Thank you for this.  The general approach looks good, but some of the finer
details should be touched up.

It makes it much easier for reviewers to understand the changes and work out
which code is being modified when patches show function names and have additional lines of context.  This can be done automatically by adding a [diff] section to ~/.hgrc or .hg/hgrc: https://developer.mozilla.org/en/Mercurial_FAQ#Configuration

>+    // We can not delete the temporary files immediately after the
>+    // drag has finished, because the target application might have not
>+    // copied the temporary file yet. Instead we collect all temporary
>+    // files in mTemporaryFiles array and remove them here in the destructor.

The destination app should not indicate that it is finished until it has
copied the file.  This seems to be implied by both the XDND and Motif
protocols:

http://newplanetsoftware.com/xdnd/dragging_files.html
http://www.lesstif.org/InsideLessTif/node89.html

So it should be safe to delete the temporary files in response to the drag-end
(or drag-failed) signals (in SourceEndDragSession()).

We don't really want to keep accumulating these files when the application
runs for months and the files would not be cleaned up if the app doesn't get a
chance to shut down nicely.

Did you see any apps that were indicating that they had finished before they
had copied the file?

In GetSourceList():

>+                        // check if application/x-moz-file-promise url is supported.
>+                        // If so, advertise text/uri-list.
>+                        if (strcmp(flavorStr, kFilePromiseURLMime) == 0) {
>+                            GdkAtom urlAtom = gdk_atom_intern(gTextUriListType, FALSE);
>+                            GtkTargetEntry *urlTarget =
>+                             (GtkTargetEntry *)g_malloc(sizeof(GtkTargetEntry));
>+                            urlTarget->target = g_strdup(gTextUriListType);
>+                            urlTarget->flags = 0;
>+                            /* Bug 331198 */
>+                            urlTarget->info = NS_PTR_TO_UINT32(urlAtom);
>+                            targetArray.AppendElement(urlTarget);
>+                        }

It looks like this can be done even when numDragItems > 1.

Though I don't think we want two gTextUriListType targets when both kURLMime
and kFilePromiseURLMime are supported flavours (unless there's a reason why
that won't happen).  If both kFilePromiseURLMime and kURLMime flavours are
available, then which should be used in the text/uri-list data?  (We won't
know whether the destination wants to copy or link.)  Perhaps they are
unlikely to both occur together and just picking one will be fine.

I don't think handling multiple files would be too difficult, but even if you
prefer to only implement this for one file right now, make sure that
SourceDataGet() is consistent with GetSourceList().

In SourceDataGet():

>+                void    *tmpData = NULL;
>+                nsresult rv;
>+                nsCOMPtr<nsISupports> data;
>+                rv = item->GetTransferData(kFilePromiseURLMime,
>+                                           getter_AddRefs(data),
>+                                           &tmpDataLen);
>+                if (NS_SUCCEEDED(rv)) {
>+                    foundFilePromiseFlavor = PR_TRUE;
>+                    if (tmpData) {

tmpData is not used.

>+            if (foundFilePromiseFlavor == PR_FALSE) {
>+                PR_LOG(sDragLm, PR_LOG_DEBUG, ("Transferable is missing kFilePromiseURLMime flavor\n"));
>+                return;
>+            }
>+

I expect the transferable may often not have kFilePromiseURLMime even though
someone asks for target type mimeFlavor == gTextUriListType.  (If kURLMime is
a supported flavour, then gTextUriListType will be in the GtkTargetList.)  This
function should continue to return gTextUriListType data even if there is no
kFilePromiseURLMime flavour.

>+            rv = NS_NewFileURI(getter_AddRefs(uri), tmpDir);

The uri will need to contain the hostname.  Will NS_NewFileURI do this?

http://newplanetsoftware.com/xdnd/dragging_files.html

Feel free to use glib functions (g_filename_to_uri() perhaps) when dealing
with GTK as in this function (and others in this file), if that makes things
easier.

>+                    // remove and re-add the text/uri-list flavor to discard any previous
>+                    // data of that flavor
>+                    item->RemoveDataFlavor(gTextUriListType);
>+                    item->AddDataFlavor(gTextUriListType);
>+
>+                    // set the file:///tmp/dnd_file/<filename> URL for text/uri-list flavor
>+                    item->SetTransferData(gTextUriListType, genericDataWrapper, ucs2Str.Length() * 2);

The side-effect of modifying the transferable here doesn't feel right to me.
The transferable is an app-internal reference to the data, while the external
uri list, generated here for the GtkSelectionData for other apps, is likely to
be different.  (Internally the data can be referenced from the original URI,
rather than from the file intended for external use.)

There is lot of code specific to kFilePromiseURLMime added to SourceDataGet()
here.  This dominates the function (which is actually much more general) and
makes it harder to follow the flow.  Most of the new code should be split out
into one or more static functions or private methods.
Attachment #390806 - Flags: review?(mozbugz)
Comment on attachment 390806 [details] [diff] [review]
New version that removes all references to attachments

>+            tmpDir->CreateUnique(nsIFile::DIRECTORY_TYPE, 0775);

Any reason for g+w here?  Is this relying on umask.

>+            rv = NS_NewLocalFileOutputStream(getter_AddRefs(outputStream), tmpDir);

And does this just use umask?

I guess the destination app will copy permissions from the file.

Often mail is considered private and apps seem to use go-r even if umask is more permissive.
We don't know that this data is mail here, but I think it would be better to err on the side of being private for this data of unknown nature:  0700 for the dir, and 0600 for the file.
(In reply to comment #57)

Hej Karl,

> It makes it much easier for reviewers to understand the changes and work out
> which code is being modified when patches show function names and have
> additional lines of context.
Ok, fixed, thanks for the hint!

> >+    // We can not delete the temporary files immediately after the
> >+    // drag has finished, because the target application might have not
> >+    // copied the temporary file yet. Instead we collect all temporary
> >+    // files in mTemporaryFiles array and remove them here in the destructor.
> 
> The destination app should not indicate that it is finished until it has
> copied the file.  This seems to be implied by both the XDND and Motif
> protocols:
Right, unfortunately the KDE applications have a bug there (well, it is actually a bug/missing feature in Qt) and they return the XDNDFinished signal
too early before they have started copying the file. I talked with the
Qt developers already, however it won't be fixed in near future, therefor
that delayed deleting would be a helpfull workaround.
(See last entry on http://www.freedesktop.org/wiki/Specifications/XDNDRevision)

> We don't really want to keep accumulating these files when the application
> runs for months and the files would not be cleaned up if the app doesn't get a
> chance to shut down nicely.
Is it so common that a Thunderbird app runs for months?

> In GetSourceList():
> 
> >+                        // check if application/x-moz-file-promise url is supported.
> >+                        // If so, advertise text/uri-list.
> >+                        if (strcmp(flavorStr, kFilePromiseURLMime) == 0) {
> >+                            GdkAtom urlAtom = gdk_atom_intern(gTextUriListType, FALSE);
> >+                            GtkTargetEntry *urlTarget =
> >+                             (GtkTargetEntry *)g_malloc(sizeof(GtkTargetEntry));
> >+                            urlTarget->target = g_strdup(gTextUriListType);
> >+                            urlTarget->flags = 0;
> >+                            /* Bug 331198 */
> >+                            urlTarget->info = NS_PTR_TO_UINT32(urlAtom);
> >+                            targetArray.AppendElement(urlTarget);
> >+                        }
> 
> It looks like this can be done even when numDragItems > 1.
Ok, will check

> I don't think handling multiple files would be too difficult, but even if you
> prefer to only implement this for one file right now, make sure that
> SourceDataGet() is consistent with GetSourceList().
Ok, will have a look.

> In SourceDataGet():
> 
> >+                void    *tmpData = NULL;
> >+                nsresult rv;
> >+                nsCOMPtr<nsISupports> data;
> >+                rv = item->GetTransferData(kFilePromiseURLMime,
> >+                                           getter_AddRefs(data),
> >+                                           &tmpDataLen);
> >+                if (NS_SUCCEEDED(rv)) {
> >+                    foundFilePromiseFlavor = PR_TRUE;
> >+                    if (tmpData) {
> 
> tmpData is not used.
> 
> >+            if (foundFilePromiseFlavor == PR_FALSE) {
> >+                PR_LOG(sDragLm, PR_LOG_DEBUG, ("Transferable is missing kFilePromiseURLMime flavor\n"));
> >+                return;
> >+            }
> >+
> 
> I expect the transferable may often not have kFilePromiseURLMime even though
> someone asks for target type mimeFlavor == gTextUriListType.  (If kURLMime is
> a supported flavour, then gTextUriListType will be in the GtkTargetList.)  This
> function should continue to return gTextUriListType data even if there is no
> kFilePromiseURLMime flavour.
Ok, have to check.

> >+            rv = NS_NewFileURI(getter_AddRefs(uri), tmpDir);
> 
> The uri will need to contain the hostname.  Will NS_NewFileURI do this?
Good to know...

> http://newplanetsoftware.com/xdnd/dragging_files.html
> 
> Feel free to use glib functions (g_filename_to_uri() perhaps) when dealing
> with GTK as in this function (and others in this file), if that makes things
> easier.
> 
> >+                    // remove and re-add the text/uri-list flavor to discard any previous
> >+                    // data of that flavor
> >+                    item->RemoveDataFlavor(gTextUriListType);
> >+                    item->AddDataFlavor(gTextUriListType);
> >+
> >+                    // set the file:///tmp/dnd_file/<filename> URL for text/uri-list flavor
> >+                    item->SetTransferData(gTextUriListType, genericDataWrapper, ucs2Str.Length() * 2);
> 
> The side-effect of modifying the transferable here doesn't feel right to me.
> The transferable is an app-internal reference to the data, while the external
> uri list, generated here for the GtkSelectionData for other apps, is likely to
> be different.  (Internally the data can be referenced from the original URI,
> rather than from the file intended for external use.)
> 
> There is lot of code specific to kFilePromiseURLMime added to SourceDataGet()
> here.  This dominates the function (which is actually much more general) and
> makes it harder to follow the flow.  Most of the new code should be split out
> into one or more static functions or private methods.
Ok, then I'll try to separate it more and send an updated Patch
(In reply to comment #59)
> (In reply to comment #57)
> > The destination app should not indicate that it is finished until it has
> > copied the file.  This seems to be implied by both the XDND and Motif
> > protocols:
> Right, unfortunately the KDE applications have a bug there (well, it is
> actually a bug/missing feature in Qt) and they return the XDNDFinished signal
> too early before they have started copying the file. I talked with the
> Qt developers already, however it won't be fixed in near future, therefor
> that delayed deleting would be a helpfull workaround.
> (See last entry on http://www.freedesktop.org/wiki/Specifications/XDNDRevision)
> 
> > We don't really want to keep accumulating these files when the application
> > runs for months and the files would not be cleaned up if the app doesn't get a
> > chance to shut down nicely.
> Is it so common that a Thunderbird app runs for months?

I assume mail apps tend to get run continuously (rather than started and quit
repeatedly) so that users are notified of new mail, so I hope Thunderbird will
run for months.

I don't know but I wonder whether or not the app shuts down cleanly when the X
session is ended.

This could be used by any app of unknown function too.

I think deleting the file on a timer could be suitable workaround.  (It would
still need to be deleted on exit as well, assuming the timer is not guaranteed
to run before exit.)

Either a glib timer (g_timeout_add? - beware we need to support glib-2.12.x) or
nsITimer should be helpful.
http://mxr.mozilla.org/mozilla-central/source/xpcom/threads/nsITimer.idl

Once the destination has a file handle, it should be safe to unlink, but it
could take a little while for the destination to get a file handle if it
prompts the user for anything.  I guess a timeout of a few minutes should be
suitable.
Just a record of my investigation into XDS:

I looked at the possibility of using the Direct Save Protocol (http://www.newplanetsoftware.com/xds/) as an alternative (more similar to MS behavior) because a blog (http://rodney.id.au/dev/gnome/an-xds-example) said that it was "supported by ROX, Thunar, Konqueror, and Nautilus file managers".

However, I can't see how GTK apps could easily implement this protocol because
GDK doesn't support XdndActionDirectSave.  Apparently that action was added
(October 26, 2000) but I don't know why it's needed.  Further, even if this
action could be provided, it would be difficult for destinations not
supporting XDS to know how to fall back to text/uri-list given the
unrecognized action.
(In reply to comment #57)
Hej Karl,

> In GetSourceList():
> 
> >+                        // check if application/x-moz-file-promise url is supported.
> >+                        // If so, advertise text/uri-list.
> >+                        if (strcmp(flavorStr, kFilePromiseURLMime) == 0) {
> >+                            GdkAtom urlAtom = gdk_atom_intern(gTextUriListType, FALSE);
> >+                            GtkTargetEntry *urlTarget =
> >+                             (GtkTargetEntry *)g_malloc(sizeof(GtkTargetEntry));
> >+                            urlTarget->target = g_strdup(gTextUriListType);
> >+                            urlTarget->flags = 0;
> >+                            /* Bug 331198 */
> >+                            urlTarget->info = NS_PTR_TO_UINT32(urlAtom);
> >+                            targetArray.AppendElement(urlTarget);
> >+                        }
> 
> It looks like this can be done even when numDragItems > 1.
> 
> Though I don't think we want two gTextUriListType targets when both kURLMime
> and kFilePromiseURLMime are supported flavours (unless there's a reason why
> that won't happen).  If both kFilePromiseURLMime and kURLMime flavours are
> available, then which should be used in the text/uri-list data?  (We won't
> know whether the destination wants to copy or link.)  Perhaps they are
> unlikely to both occur together and just picking one will be fine.
So what shall I do? Checking whether an kURLMime/gTextUriListType already exists and only create a new gTextUriListType entry if not?

> I don't think handling multiple files would be too difficult, but even if you
> prefer to only implement this for one file right now, make sure that
> SourceDataGet() is consistent with GetSourceList().
What exactly do you mean with consistent?

> >+                    // remove and re-add the text/uri-list flavor to discard any previous
> >+                    // data of that flavor
> >+                    item->RemoveDataFlavor(gTextUriListType);
> >+                    item->AddDataFlavor(gTextUriListType);
> >+
> >+                    // set the file:///tmp/dnd_file/<filename> URL for text/uri-list flavor
> >+                    item->SetTransferData(gTextUriListType, genericDataWrapper, ucs2Str.Length() * 2);
> 
> The side-effect of modifying the transferable here doesn't feel right to me.
> The transferable is an app-internal reference to the data, while the external
> uri list, generated here for the GtkSelectionData for other apps, is likely to
> be different.  (Internally the data can be referenced from the original URI,
> rather than from the file intended for external use.)
So how can I return the url of the temporary file instead of changing the transferable?!?

Ciao,
Tobias
(In reply to comment #62)
> (In reply to comment #57)

> > If both kFilePromiseURLMime and kURLMime flavours are
> > available, then which should be used in the text/uri-list data?  (We won't
> > know whether the destination wants to copy or link.)  Perhaps they are
> > unlikely to both occur together and just picking one will be fine.

> So what shall I do? Checking whether an kURLMime/gTextUriListType already
> exists and only create a new gTextUriListType entry if not?

In GetSourceList() when numDragItems > 1, gTextUriListType is the only target
that will be supported, so it's fine to break from the loop when the first is
added.

The real decision will be in SourceDataGet() (or CreateUriList) when choosing
whether to provide the uri from the kFilePromiseURLMime or kURLMime flavor.  I
don't know what the right answer is.  I'd be happy with even just a comment
indicating that it is not clear which is better.

> > make sure that SourceDataGet() is consistent with GetSourceList().
> What exactly do you mean with consistent?

It's probably enough to make sure that SourceDataGet does
gtk_selection_data_set for targets that are advertised in GetSourceList.  (I
can't remember but I was probably also thinking that data should not be set
for targets that were not advertised, but that principal doesn't appear to be
satisfied in current code anyway.)

> So how can I return the url of the temporary file instead of changing the
> transferable?!?

Return it using gtk_selection_data_set().  I expect CreateUriList() will
probably need some modification.
The new patch has the following improvements
  - uses a timer to delete the list of temporary files
  - uses gtk_selection_data_set instead of changing the Transferable object
  - code that creates temporary file is located in separated method
Attachment #390806 - Attachment is obsolete: true
Attachment #403730 - Flags: review?(mozbugz)
Comment on attachment 403730 [details] [diff] [review]
Patch that addresses the problems from previous review

Thanks, again!  Sorry for the delay on this.

>+  // We can not delete the temporary files immediately after the
>+  // drag has finished, because the target application might have not
>+  // copied the temporary file yet. Instead we collect all temporary
>+  // files in mTemporaryFiles array and remove them here in the timer event.

Can you be more specific about the Qt issue please, so that we will know when
it is fixed and this code can be removed?  A link to a bug report would be
ideal.

>+  PRUint32 count = mTemporaryFiles.Count();
>+
>+  while (count > 0) {
>+    --count;
>+    mTemporaryFiles[count]->Remove(PR_TRUE);
>+  }

A "for" loop would work well here.

>+    mTempFileCreated = false;

Use PR_FALSE for PRBools.

>+nsresult GetDownloadDetails(nsITransferable * aTransferable, nsIURI **aSourceURI, nsAString &aFilename)

This function can be static and file style is to put the function name on a
new line.

Can you move this to just above CreateTempFile(), where it is used, please?

>+  NS_ENSURE_TRUE(aTransferable, NS_ERROR_FAILURE);

NS_PRECONDITION is better here.  It is a debug-only check; it shouldn't be
necessary to check in production code.

>+  NS_ENSURE_TRUE(srcUrlPrimitive, NS_ERROR_FAILURE);

Consensus seems to be to deprecate NS_ENSURE_TRUE, and I agree:
http://groups.google.com/group/mozilla.dev.platform/browse_thread/thread/ccb87d7e7d9e688f

Instead, use something like:

  if (!srcUrlPrimitive)
    return NS_ERROR_FAILURE;

>+    mTimer->Cancel();
>+    mTimer->InitWithCallback(static_cast<nsITimerCallback*>(this), 
>+                             NS_DND_TIMEOUT,
>+                             nsITimer::TYPE_ONE_SHOT);

This looks like a sensible place to cancel the previous timer.

A better place to start the timer would be SourceEndDragSession().

Can you update the comment for NS_DND_TIMEOUT to explain the new use, please?

>+    outputStream->Close();

I think this is the place to check that buffers have been successfully flushed
to disk.  (No need to check inputStream->Close().)

>+            char hostname[255];
>+            gethostname(hostname, sizeof(hostname));

Need to ensure that there is a NUL terminator here.
(Just make the last byte NUL.)

>+            nsCAutoString hostnameStr;
>+            hostnameStr.AssignASCII(hostname);
>+
>+            fileURL->SetHost(hostnameStr);

The string copy can be skipped by using:

  fileURL->SetHost(nsDependentCString(hostname))

>+        if (strcmp(mimeFlavor, gTextUriListType) == 0) {
>+            PRUint32 i, count;
>+            mSourceDataItems->Count(&count);
>+
>+            // check whether transferable contains FilePromiseUrl flavor...
>+            PRBool foundFilePromiseFlavor = PR_FALSE;
>+            for (i = 0; i < count; i++) {

kFilePromiseURLMime was only advertised (in GetSourceList) as a uri-list when
numDragItems == 1 and only one temporary file will be created, so only
consider providing the temporary file when numDragItems == 1.

Can this block be merged with the previous "strcmp(mimeFlavor,
gTextUriListType) == 0" block?

>+                NS_ConvertUTF16toUTF8 tempFileUrl(mTempFileUrl);

By making mTempFileUri a nsCString, this conversion can be moved to
CreateTempFile() (and will only need to be done once).

>+    // stores whether a temporary file has been created for the
>+    // current drag session
>+    PRBool              mTempFileCreated;
>+
>+    nsString            mTempFileUrl;
>+
>+    // stores all temporary files
>+    nsCOMArray<nsIFile> mTemporaryFiles;
>+
>+    // timer to trigger deletion of temporary files
>+    nsCOMPtr<nsITimer>  mTimer;

It is normally best to declare member variables together so as to make it
clearer how best to pack them.  Unfortunately there are already two groups of
member variables in this class declaration, but try to keep the variables as
close as practical.

Can mTempFileUrl.IsEmpty() be used to make mTempFileCreated unnecessary?
Or maybe keeping mTempFileCreated would make it easier to know when to set the timer.

If keeping mTempFileCreated, the PRBool would pack better with the other PRBool members (and they should really all be PRPackedBool).

Resetting mTempFileUrl or mTempFileCreated is logically necessary in
the same places as mSourceDataItems is initialized.  The places you have initialized
mTempFileCreated are sufficient, but it would be clearer if temp file variable
initialization for each drag was moved to where mSourceDataItems is
initialized.

mTimer could have a more specific name such as mTempFileTimer or similar.
Attachment #403730 - Flags: review?(mozbugz)
This patch should fix all mentioned issues. Only the 'check that all data are flushed' confused me... doesn't Close() flush the stream automatically before it closes?
Attachment #403730 - Attachment is obsolete: true
Attachment #411924 - Flags: review?(mozbugz)
Blocks: 478169
Comment on attachment 411924 [details] [diff] [review]
Patch that addresses the issues found on previous review

(In reply to comment #68)
> This patch should fix all mentioned issues. Only the 'check that all data are
> flushed' confused me... doesn't Close() flush the stream automatically before
> it closes?

Yes, it tries to, but that may not succeed.  Check the return value of
outputStream->Close() to see whether it succeeded.

>+  // (http://bugreports.qt.nokia.com/browse/QTBUG-5441)

Thanks for filing that.  That looks like a sensible suggestion (from my
limited understanding of the Qt APIs).

>+    tmpDir->CreateUnique(nsIFile::DIRECTORY_TYPE, 0700);

I think there should be a check for success here before adding to
mTemporaryFiles to be deleted.

The directory is created here, but this function can still fail to set
mTempFileUri (after cancelling the timer) ...

>+    if (!mTempFileUrl.IsEmpty()) {
>+        // start time to remove temporary files
>+        mTempFileTimer->InitWithCallback(static_cast<nsITimerCallback*>(this), 
>+                                         NS_DND_TIMEOUT,
>+                                         nsITimer::TYPE_ONE_SHOT);

so I think this should check mTemporaryFiles.Count() instead of mTempFileUrl.

>+                // check whether transferable contains FilePromiseUrl flavor...
>+                PRBool foundFilePromiseFlavor = PR_FALSE;
>+                PRUint32 i;
>+                for (i = 0; i < numDragItems; i++) {

No need for a loop here as numDragItems == 1.
Attachment #411924 - Flags: review?(karlt)
Assignee: tokoe → nobody
Component: Mail Window Front End → Widget: Gtk
Product: Thunderbird → Core
QA Contact: front-end → gtk
Assignee: nobody → tokoe
I can also confirm this in Thunderbird 3.1.7 on Ubuntu 10.4 (Gnome 
With a warning message:
Error while copying.
There was an error getting information about "[folder_name]>[number]".
An in the show more details:
The specified location is not supported

Lorenzo.
Repeated comments are not going to help get the bug fixed any faster. Please stop commenting unless you're willing to take on the bug or have a patch.
The behaviour changed. Now when I drag and drop, on Ubuntu 11.10, i have a ".desktop" file created with a "link" to the mail object. The problem is that

1) clicking on the icon give the error Could not display "imap://romano%2Egiannetti%40...1.2&filename=13008%202011.pdf". 

2) ...and even if I manage to open it (I can, with some opening and cut and paste and based on the fact that the application understand the URI) what happens if I go offline? 

So I think it's worst than ever --- before you had an error, now it could seem that the operation succeeded.
Not sure it's worse but it seems not what we are used to.
All mail clients I know (and also Thunderbird) create a new file with a full copy of the attachment. That seems to create a link to the attachment. If wonder what happens if one edits the saved attachment (let's say it's a .doc on .odt) but I bet that it's just a bug, not the intended behavior.
I did a fresh install of Ubuntu 11.10 and installed some alternative desktop environments.
The behavior with the Unity and the GNOME desktops is what Romano describes.
With MATE (the Linux Mint desktop) I get the old error "The specified location is not supported".
That could mean that the error is in how the desktop environment handles the information passed to it by TB,
Summary: Drag and Drop attachments to desktop or folders doesn't work → Drag and Drop attachments / bookmarks to desktop or folders doesn't work
Summary: Drag and Drop attachments / bookmarks to desktop or folders doesn't work → Drag and Drop attachments to desktop or folders doesn't work
Depends on: 396370
Maybe we could use http://bribe.io/ to fix this when it will launch. I'm mostly kidding but I'm also thinking a little about it. However this bug is older than the first iPhone (April vs June 2007) so I wonder if there is anybody left in the dev team with the knowledge to fix it.
Assignee: tokoe → nobody
@Paolo: sadly, it's probably true. I suppose we all got to grip with it (I just stopped trying it and right-click and save, you know, even in other mailer) but it is a very nasty (and, let me say, discreting) bug to have around for so much time.
s/discreting/discrediting/ in the last message.
I am using Thunderbird 24.5.0 on OpenSuse 13.1 with KDE 4.13.0. Trying to Drag and Drop an attachment to the Dolphin file manager only shows a menu for "link" (no copy). Clicking on "link" creates a .desktop file with a link to the attachment in the message. Clicking on the link just opens an empty location - the attachment does not open. It would be good if this behaviour is fixed.
If I can chime in with a comment to the developers (if anyone is listening here): I am used to never use drag and drop of attachment on TB now, given the really broken behavior. 

Suggestion: ditch the thing completely. Remove drag and drop. For good.

It's so broken it is more a danger(1) than any other thing, and it is not so necessary in the end, you can live with "save as..." and company. I suppose that a bug like that not fixed in 7 years means it's too complex to fix; let's accept it and move on. Leaving an half-baked functionality is much worse than not having it.



(1) because sometime it *seems* to work; it creates an icon from which the content is not accesible at all, and can lead to data loss for unsuspecting users.
+1  Romano Giannetti 
Suggestion: ditch the thing completely. Remove drag and drop. For good.
Whiteboard: tpi:-
Flags: in-litmus?
Yes, still here; will not disappear alone. 

I still think that the worst problem of this bug is that is _seems_ to work, and can lead to data loss. It would be much better to forbid the drag and drop completely, if fixing it is too difficult.
It seems that the firefox bug (which is listed as a duplicate, I do not think is 100% correct) #396370 has been marked as fixed. Could this be the case for thunderbird also? That would be great...
That would be great...
+1

This issue is noticed on Windows 10 as well. Windows is updated. TB re-installed and still doesn't work.
Tested a new User Account and still the same.

In version 78.7.1 the behavior is better: still not working, but it raises an error instead of copying an unusable link.
The error is also ok: "drag and drop not supported".

Definitely better!

I can reproduce it with TB91.

Priority: -- → P2
Summary: Drag and Drop attachments to desktop or folders doesn't work → [Thunderbird] Drag and Drop attachments to desktop or folders doesn't work

Managed to update the patch to latest trunk so let's fix this one.

Assignee: nobody → stransky

When application/x-moz-file-promise MIME content is adverised, save the file to /tmp/dnd_file-*/ directory and
offer it as text/uri-list MIME type.

Based on patches by Phil Lacy and Tobias Koenig.

Pushed by stransky@redhat.com:
https://hg.mozilla.org/integration/autoland/rev/3b98ceafb59a
[Linux] Support application/x-moz-file-promise mime type by text/uri-list, r=karlt
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 96 Branch

Thank you!

I have Manjaro Linux with TB 102, and the problem is still here. When I do drag-and-drop to a Nemo folder I got the icon copied, and when going to Nautilus I still have "Drag and drop not supported", "an invalid drag type was used".

Ubuntu 20.04
Thunderbird 102.2.2
Thunar 4.16.10

Not work. Location specified is not compatible.

I have Manjaro Linux with TB 102, and the problem is still here.
...
Not work. Location specified is not compatible.

Bugs fixed long ago is not a great place to be reporting current issues. If it reproduces under Help > Troubleshooting Mode then please file a new bug report

Will look at it - still reproducible on TB 102.

Status: RESOLVED → REOPENED
Resolution: FIXED → ---

In the process of migrating remaining bugs to the new severity system, the severity for this bug cannot be automatically determined. Please retriage this bug using the new severity system.

Severity: major → --

It's because we added text/uri-list but we still support _NETSCAPE_URL so an application can select _NETSCAPE_URL and we provide an url with "mailbox:///" prefix. We should filter out such internal URL.

If we can detect a drop target is a different application (not thunderbird itself) we may alter URL from mailbox:/// to file:/// and copy the file to /tmp.

_NETSCAPE_URL hints target application it should store URL link instead of copy the pointed data.
Don't use that for internal URL (mailbox:/// and similar).

Depends on D161441

Pushed by stransky@redhat.com:
https://hg.mozilla.org/integration/autoland/rev/cc7972f31488
[Linux] Log correctly MIME type conversions r=emilio
https://hg.mozilla.org/integration/autoland/rev/0cea06c45ea2
[Linux] Don't advertise _NETSCAPE_URL MIME type for internal data r=emilio
Status: REOPENED → RESOLVED
Closed: 2 years ago1 year ago
Resolution: --- → FIXED

The D&D is still a bit broken but let's finish it at Bug 1800972. It also adds support for multiple file transfer.

See Also: → 1800972
You need to log in before you can comment on or make changes to this bug.