Drag and Drop Issue

Open forum for end-user questions about Wine. Before asking questions, check out the Wiki as a first step.
Forum Rules
Locked
TT-ReBORN
Newbie
Newbie
Posts: 2
Joined: Thu May 27, 2021 12:00 pm

Drag and Drop Issue

Post by TT-ReBORN »

Hello Wine-Community,

I'm the creator of the Georgia-ReBORN theme for foobar2000 which runs in a full Spider Monkey Panel and works perfectly on Windows.
Here is the official link to the theme: https://github.com/TT-ReBORN/Georgia-ReBORN

I also want users to be able to run it in Wine and not being restricted for Windows only but I have an issue with drag and drop.

Installed foobar v1.6.6 and tested on both Wine 6.0.1 and Wine 6.11 with Mono/Gecko, GDI+

Now the issue about the drag and drop:

You can drag ( selection is displayed ) the music folder onto the playlist, a plus icon will be also displayed but if you drop nothing happens.
No music files are added, the command/execution will be ignored...

Here is the log from the console:

Code: Select all

00f4:fixme:clipboard:import_text unsupported TEXT type "TEXT" 00f4:fixme:shell:IDropTargetHelper_fnDragEnter (0x205998)->(0x10078 0x7db4b3b8 0x31f9a0 0x00000001) 00f4:fixme:xdnd:XDNDDATAOBJECT_SetData (0x7db4b3b8, 0x31f4a8, 0x31f4bc, TRUE): stub 00f4:fixme:shell:IDropTargetHelper_fnDragOver (0x205998)->(0x31f9a0 0x00000001) 00f4:fixme:xdnd:XDNDDATAOBJECT_SetData (0x7db4b3b8, 0x31f4c8, 0x31f4dc, TRUE): stub 00f4:fixme:xdnd:X11DRV_XDND_DROPEFFECTToXdndAction unknown drop effect 0, assuming XdndActionCopy 00f4:fixme:shell:IDropTargetHelper_fnDragOver (0x205998)->(0x31f9a0 0x00000001) 00f4:fixme:xdnd:XDNDDATAOBJECT_SetData (0x7db4b3b8, 0x31f4c8, 0x31f4dc, TRUE): stub 00f4:fixme:xdnd:X11DRV_XDND_DROPEFFECTToXdndAction unknown drop effect 0, assuming XdndActionCopy 00f4:fixme:shell:IDropTargetHelper_fnDragOver (0x205998)->(0x31fa60 0x00000001) 00f4:fixme:xdnd:XDNDDATAOBJECT_SetData (0x7db4b3b8, 0x31f588, 0x31f59c, TRUE): stub 00f4:fixme:xdnd:X11DRV_XDND_DROPEFFECTToXdndAction unknown drop effect 0, assuming XdndActionCopy 00f4:fixme:shell:IDropTargetHelper_fnDragOver (0x205998)->(0x31f9a0 0x00000001) 00f4:fixme:xdnd:XDNDDATAOBJECT_SetData (0x7db4b3b8, 0x31f4c8, 0x31f4dc, TRUE): stub 00f4:fixme:xdnd:X11DRV_XDND_DROPEFFECTToXdndAction unknown drop effect 0, assuming XdndActionCopy 00f4:fixme:shell:IDropTargetHelper_fnDragLeave (0x205998)->() 00f4:fixme:xdnd:XDNDDATAOBJECT_SetData (0x7db4b3b8, 0x31f430, 0x31f444, TRUE): stub
I don't know if it's a problem with the Spider Monkey Panel or with Wine...

All other Wine issues with Georgia-ReBORN are documented here:
https://github.com/TT-ReBORN/Georgia-ReBORN/issues/2

Btw if you open and use Wine Explorer, drag and drop music files to the playlist is working.
Also native drag and drop in original foobar works.


Any Ideas? I would appreciate your help!
Thank you!

-TT
TT-ReBORN
Newbie
Newbie
Posts: 2
Joined: Thu May 27, 2021 12:00 pm

Re: Drag and Drop Issue

Post by TT-ReBORN »

Hello,

the developer of Spider Monkey Panel has found out what the problem is,
can someone please forward this reply to the Wine dev's so it can be fixed?

Thank you

-TT

--------------------------------------------------------------------------------------------------------------

Okay, I've found what the problem is: it's a WINE bug =)

Their DnD implementation does not set DROPEFFECT correctly (it's always zero).

DnD operations are supposed to work like this:

Code: [Select]
function DnD_Operation(allowed_effects) {
// do stuff
effect_to_apply = SelectSomeEffect(allowed_effects);
return effect_to_apply;
}

In WINE implementation `allowed_effects` is always equal to zero (DROPEFFECT_NONE), which means that no effects are allowed.
My theme (and yours by extension) respects the allowed effects, while in FooTuner they just ignore the `allowed_effects` field and just return whatever `effect_to_apply` they need.

Corresponding WinAPI docs:
https://docs.microsoft.com/en-us/window ... -dragenter
Quote
Code: [Select]
HRESULT DragEnter(
IDataObject *pDataObj,
DWORD grfKeyState,
POINTL pt,
DWORD *pdwEffect
);

pdwEffect: On input, pointer to the value of the pdwEffect parameter of the DoDragDrop function. On return, must contain one of the DROPEFFECT flags, which indicates what the result of the drop operation would be.

https://docs.microsoft.com/en-us/window ... dodragdrop
Quote
Code: [Select]
HRESULT DoDragDrop(
LPDATAOBJECT pDataObj,
LPDROPSOURCE pDropSource,
DWORD dwOKEffects,
LPDWORD pdwEffect
);

dwOKEffects: Effects the source allows in the OLE drag-and-drop operation. Most significant is whether it permits a move. The dwOKEffect and pdwEffect parameters obtain values from the DROPEFFECT enumeration. For a list of values, see DROPEFFECT.

In WINE `dwOKEffects` is equal to DROPEFFECT_NONE
Locked