SunDropTargetEvent event =
new SunDropTargetEvent(component,
SunDropTargetEvent.MOUSE_DRAGGED,
x, y, dispatcher);
ToolkitThreadBlockedHandler handler =
DataTransferer.getInstance().getToolkitThreadBlockedHandler();
handler.lock();
try {
SunToolkit.postEvent(SunToolkit.targetToAppContext(component),
event);
while (!dispatcher.isDone()) {
handler.enter();
}
}
finally {
handler.unlock();
}
// return target's response
return dispatcher.getReturnValue();
}