EnableWindowDrop()
Syntax
EnableWindowDrop(#Window, Format, Actions [, PrivateType])Description
Enables a window to be a target for Drag & Drop operations of a specific format. Only the area not covered by any gadgets will be the target area. When the user drags data of this format over the window, the cursor will indicate that the data can be dropped there.
If data was dropped on the window, the program will receive a #PB_Event_WindowDrop event. EventWindow() will indicate the target window and the Event functions of this library can be used to get the dropped data.
Parameters
#Window is the PureBasic window number for the window in question.
Format specifies the data format and can be one of the following values, or an OS specific ID for a custom format (see DragOSFormats() for more information).#PB_Drop_Text : Accept text on this window #PB_Drop_Image : Accept images on this window #PB_Drop_Files : Accept filenames on this window #PB_Drop_Private: Accept a "private" Drag & Drop on this windowActions can be a combination of the Drag & Drop actions that should be allowed for the data. The user can decide which of these actions to take by pressing modifier keys like Ctrl or Shift. The actions that can really be taken also depend on the actions allowed by the drag source. Possible actions are: (they can be combined with '|')#PB_Drag_None: The data format will not be accepted on the window #PB_Drag_Copy: The data can be copied #PB_Drag_Move: The data can be moved #PB_Drag_Link: The data can be linkedPrivateType is only needed when #PB_Drop_Private is specified as format. It specifies the type of private Drag & Drop to accept. See DragPrivate() for more information.
Note: Multiple formats can be allowed on the same window. If the drag source provides multiple formats that match the list of accepted formats, the one that was added last will be accepted. So the preferred format in which to receive data should be enabled last.
Supported OS
All