On Wed, Feb 09, 2005 at 09:00:10PM +0000, Mike Hearn wrote:
Niceness Don. Of course, it'd rock more if this had worked out of the box. I expect we're missing some shell magic for the recycle bin. Wouldn't be hard to investigate but have a million other things to do so I'll CC this to wine-devel.
Context is: app has a "send to recycle bin" option to delete photos. Doesn't work. Native shell32/shfolder fixes it. If anybody is up for what is probably an easy task, figure out why and fix it so c:\Recycled is used.
For bonus points we should bridge it to KDE/GNOME so if an app recycles something it appears in your actual trash can :)
comment in dlls/shell32/shlfileop.c says: "unimplemented and break if any other flag set: FOF_ALLOWUNDO, FOF_WANTMAPPINGHANDLE". FOF_ALLOWUNDO = 0x40 is the flag that says to use the Recycle Bin, if available. Note that Windows itself doesn't use the recycle bin on network drives or removable disks.
Probably some extra logic could be added around line 1085 to issue a 'rename' (or MoveFileEx) call in either of the following situations:
1. The file is under the user's home directory; move it to ~/Desktop/Trash or ~/.gnome-desktop/Trash
2. The file is on a VFAT partition; move it to $(MOUNT_POINT)/Recycled
However, the app in question is probably upset about something else, and there are still some stub functions in that file, so I doubt that a "correct Recycle Bin" is first-priority for the Wine team.