MainForm(Drag'n Drag) - Fix target node being null

This commit is contained in:
miku-666
2024-04-20 22:29:11 +02:00
parent 1622ea72ac
commit 99a04c25a4

View File

@@ -1445,6 +1445,9 @@ namespace PckStudio
// Retrieve the node at the drop location.
TreeNode targetNode = treeViewMain.GetNodeAt(targetPoint);
if (targetNode is null)
return;
bool isTargetPckFile = targetNode.IsTagOfType<PckFileData>();
if (e.Data.GetData(dataFormat) is not TreeNode draggedNode)