mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
EA-22481 - NPE: DesignDropTargetListener.dragOver
This commit is contained in:
+6
-2
@@ -152,11 +152,15 @@ class DesignDropTargetListener implements DropTargetListener {
|
||||
ComponentDropLocation location = myGridInsertProcessor.processDragEvent(dtde.getLocation(), myComponentDragObject);
|
||||
if (!location.canDrop(myComponentDragObject) ||
|
||||
(myDraggedComponentList != null && FormEditingUtil.isDropOnChild(myDraggedComponentList, location))) {
|
||||
myComponentTree.setDropTargetComponent(null);
|
||||
if (myComponentTree != null) {
|
||||
myComponentTree.setDropTargetComponent(null);
|
||||
}
|
||||
dtde.rejectDrag();
|
||||
}
|
||||
else {
|
||||
myComponentTree.setDropTargetComponent(location.getContainer());
|
||||
if (myComponentTree != null) {
|
||||
myComponentTree.setDropTargetComponent(location.getContainer());
|
||||
}
|
||||
dtde.acceptDrag(dtde.getDropAction());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user