documentSource.setLayoutData(fdata1);
documentSource.setToolTipText("Document source folder...");
documentSource.setMessage("Document source folder...");
DropTarget dt = new DropTarget(documentSource, DND.DROP_DEFAULT | DND.DROP_MOVE);
dt.setTransfer(new Transfer[] { FileTransfer.getInstance() });
dt.addDropListener(new DropTargetAdapter() {
@Override
public void drop(DropTargetEvent event) {
String fileList[] = null;
FileTransfer ft = FileTransfer.getInstance();
if (ft.isSupportedType(event.currentDataType)) {
fileList = (String[]) event.data;
}
if (fileList != null && fileList.length > 0) {
String fileString = fileList[0];
documentSource.setText(fileString);
}
}
});
documentSink = new Text(this, SWT.SINGLE | SWT.BORDER);
FormData fdatag = new FormData();
fdatag.width = 200;
fdatag.left = new FormAttachment(0, 1000, 5);
fdatag.top = new FormAttachment(0, 1000, 30);
fdatag.right = new FormAttachment(1000, 1000, -5);
documentSink.setLayoutData(fdatag);
documentSink.setToolTipText("Document gold output folder...");
documentSink.setMessage("Document gold output folder...");
DropTarget dtg = new DropTarget(documentSink, DND.DROP_DEFAULT | DND.DROP_MOVE);
dtg.setTransfer(new Transfer[] { FileTransfer.getInstance() });
dtg.addDropListener(new DropTargetAdapter() {
@Override
public void drop(DropTargetEvent event) {
String fileList[] = null;
FileTransfer ft = FileTransfer.getInstance();
if (ft.isSupportedType(event.currentDataType)) {
fileList = (String[]) event.data;
}
if (fileList != null && fileList.length > 0) {
String fileString = fileList[0];
documentSink.setText(fileString);
}
}
});
typeSystem = new Text(this, SWT.SINGLE | SWT.BORDER);
FormData fdata2 = new FormData();
fdata2.width = 200;
fdata2.left = new FormAttachment(0, 1000, 5);
fdata2.top = new FormAttachment(0, 1000, 55);
fdata2.right = new FormAttachment(1000, 1000, -5);
typeSystem.setLayoutData(fdata2);
typeSystem.setToolTipText("Type System...");
typeSystem.setMessage("Type System...");
DropTarget dt1 = new DropTarget(typeSystem, DND.DROP_DEFAULT | DND.DROP_MOVE);
dt1.setTransfer(new Transfer[] { FileTransfer.getInstance() });
dt1.addDropListener(new DropTargetAdapter() {
@Override
public void drop(DropTargetEvent event) {
String fileList[] = null;
FileTransfer ft = FileTransfer.getInstance();
if (ft.isSupportedType(event.currentDataType)) {