
A drag and drop help dialog
The new HandleDropLabel() routine handles the case when the dropAction field is set to XmDROP_HELP. In
this case, the routine creates an InformationDialog if it has not already been created. The HandleDropOK() and
HandleDropCancel() routines are registered for the OK and Cancel buttons in the dialog. If the dialog already
exists, the necessary fields in the client structure are specified so that the callback structure information is passed
to the callback routines as client data. If the user has performed a normal drop operation, the drop proceeds just as it
did in editor_dnd.c.
The HandleDropOK() routine is invoked when the user presses the OK button in the help dialog. This routine
proceeds with the drop by calling XmDropTransferStart(). The status of the transfer is based on whether the
drop performs a copy operation or not. HandleDropCancel() cancels the drop when the user presses the Cancel
button by -calling XmDropTransferStart() with XmN-transferStatus set to XmTRANS-FER_FAILURE.
One thing to note about both of these procedures is that they get the XmDropProcCallbackStruct from the
client_data parameter, since the call_data parameter is the callback structure for the dialog.
19.5.5 Providing Custom Drag−under Visuals
Under the preregister protocol, the drop site does not participate during the drag. The initiating application handles the
drag−under visual effects ...