Refactor Import structure

This commit is contained in:
miku-666
2025-12-29 00:59:39 +01:00
parent b17e8fcea5
commit a4371fae56
59 changed files with 3055 additions and 1089 deletions

View File

@@ -41,7 +41,7 @@ namespace PckStudio.Core.Extensions
if (string.IsNullOrWhiteSpace(nodeText))
return BuildNodeTreeBySeperator(root, subPath, seperator, maxDepth - 1);
TreeNode subNode = root.ContainsKey(nodeText) ? root[nodeText] : root.CreateNode(nodeText);
TreeNode subNode = root.ContainsKey(nodeText) ? root.Find(nodeText, searchAllChildren: false).FirstOrDefault(node => node.Tag is null) ?? root.CreateNode(nodeText) : root.CreateNode(nodeText);
return BuildNodeTreeBySeperator(subNode.Nodes, subPath, seperator, maxDepth - 1);
}