Hello,
Consider this code:
final DragAndDropWrapper dropTarget = new DragAndDropWrapper(root);
dropTarget.setDropHandler(new DropHandler() {
@Override
public void drop(DragAndDropEvent event) {
try {
if (event == null) handleNullPointer("event");
if (event.getTransferable() == null) handleNullPointer("event.getTransferable()");
if (event.getTransferable().getSourceComponent() == null) handleNullPointer("event.getTransferable().getSourceComponent()");
The last line is occasionally triggering the null handler. What are the circumstances that could result in event.getTransferable().getSourceComponent() returning null? I can’t repeat it and it doesn’t appear my clients can either. It just happens once in a while. Could it be a weak reference of some kind?
Thanks.
/Daryl