if (control instanceof Label) { int formHandle = OS.XtParent (control.handle); OS.XmDropSiteRegister(formHandle, args, args.length / 2); }
void registerDropTarget() {	if (control == null || control.isDisposed() || registered) return;	int[] args = new int[]{		OS.XmNdropSiteOperations, opToOsOp(getStyle()),		OS.XmNdropSiteActivity,   OS.XmDROP_SITE_ACTIVE,		OS.XmNdropProc,           DropProc.getAddress(),		OS.XmNdragProc,           DragProc.getAddress(),		OS.XmNanimationStyle,     OS.XmDRAG_UNDER_NONE,		OS.XmNdropSiteType,       OS.XmDROP_SITE_COMPOSITE,	};		if (transferAgents.length != 0) {		TransferData[] transferData = new TransferData[0];		for (int i = 0, length = transferAgents.length; i < length; i++){			TransferData[] data = transferAgents[i].getSupportedTypes();			TransferData[] newTransferData = new TransferData[transferData.length +  data.length];			System.arraycopy(transferData, 0, newTransferData, 0, transferData.length);			System.arraycopy(data, 0, newTransferData, transferData.length, data.length);			transferData = newTransferData;		}				int[] atoms = new int[transferData.length];		for (int i = 0, length = transferData.length; i < length; i++){			atoms[i] = transferData[i].type;		}			// Copy import targets to global memory 		int pImportTargets = OS.XtMalloc(atoms.length * 4);		OS.memmove(pImportTargets, atoms, atoms.length * 4);				int[] args2 = new int[]{			OS.XmNimportTargets,      pImportTargets,			OS.XmNnumImportTargets,   atoms.length		};				int[] newArgs = new int[args.length + args2.length];		System.arraycopy(args, 0, newArgs, 0, args.length);		System.arraycopy(args2, 0, newArgs, args.length, args2.length);		args = newArgs;		}		OS.XmDropSiteRegister(control.handle, args, args.length / 2);	//if (control instanceof Label) {	//	int formHandle = OS.XtParent (control.handle);	//	OS.XmDropSiteRegister(formHandle, args, args.length / 2);	//}	registered = true;}