Closed Bug 256173 Opened 20 years ago Closed 18 years ago

drag-drop of images to desktop fails occasionally, either with error or zero-byte file

Categories

(Core :: DOM: Copy & Paste and Drag & Drop, defect)

x86
Windows XP
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 267426

People

(Reporter: subscribe, Unassigned)

Details

User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.1) Gecko/20040707 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.1) Gecko/20040707 When I drag an image from a web page to the Windows desktop or any open folder window, the image file created is sometimes empty (zero bytes). A few times, an error message appears (to the effect that another application is using the file). One can typically workaround problem by repeating the drag-drop operation. The file is often created successfully on the second, third, or fourth try. Occasionally, the file is never created. The fool-proof workaround: right-click the image, and select Save Image As... Reproducible: Sometimes Steps to Reproduce: 1. Load any web page 2. Drag an image (JPG, GIF, etc.) from the page to the Windows desktop (or any open folder) 3. Examine results. 4. If file is empty, repeat drag operation until valid file is created. Subsequent filenames are numbered (e.g. filename-1.jpg, filename-2.jpg). Actual Results: Sometimes, the file is empty (zero bytes). Other times, the file is intact. Usually (but not always), repeating the drag operation eventually results in a valid file. Expected Results: A valid image file should be created each and every time, as reliably as right-clicking and selecting "Save Image As..."
Component: XP Apps: Drag and Drop → Browser-General
Component: Browser-General → XP Apps: Drag and Drop
It appears that Mozilla is creating a 0 byte file in the user temp directory and placing the path to that file in the FileDrop format of the dataObject attached to the drag/drop. Interestingly, there is a .url file with a valid path available in the FileContents format of the dataObject. Why not simply use the same path that the URL of the .Url file is pointing at in the FileDrop?
Duplicate of bug 267426?
I can't tell if this is a dupe of bug 267426, since that one involves clearing your cache, but this bug is definitely present and annoying. Here's a quick mention from the author of Total Commander: Total Commander :: View topic - Drag & drop images from Firefox? http://www.ghisler.ch/board/viewtopic.php?t=5772 "Sorry, I haven't found a way yet to correct this problem. When FF reports the drop to Total Commander, the file exists, but it is empty."
*** This bug has been marked as a duplicate of 253711 ***
Status: UNCONFIRMED → RESOLVED
Closed: 18 years ago
Resolution: --- → DUPLICATE
Hm, maybe not a dupe as this is images dragged from a web page. However the root cause is probably the same - the temporary cope of the file being made...
Right, not Mailnews. It is fixed on Trunk (FF 3.0/SeaMonkey 1.5).
You need to log in before you can comment on or make changes to this bug.