dnd

fnbool dnd() nothrow @nogc

Initiates a drag and drop operation.

Call this from a widget's handle() method when starting a drag. The function returns when the drop is completed or cancelled.

Before calling dnd(), you should copy the drag data to the clipboard using copy().

Returns

true if the drop was accepted by a target

Example:

// In a custom widget's event handler:
copy(dragData, ClipboardType.clipboard);
if (dnd()) {
   // Drop was accepted
}