mirror of
https://git.do.srb2.org/STJr/UltimateZoneBuilder.git
synced 2024-11-23 04:12:12 +00:00
UDBScript: fixed a problem where hot reloading would not select the previously selected script
This commit is contained in:
parent
8c30cef65e
commit
e1672281e6
1 changed files with 4 additions and 1 deletions
|
@ -235,7 +235,6 @@ namespace CodeImp.DoomBuilder.UDBScript
|
|||
|
||||
filetree.Nodes.Clear();
|
||||
filetree.Nodes.AddRange(AddToTree(filtertext, BuilderPlug.Me.ScriptDirectoryStructure));
|
||||
//filetree.ExpandAll();
|
||||
|
||||
foreach(TreeNode node in filetree.Nodes)
|
||||
{
|
||||
|
@ -259,6 +258,10 @@ namespace CodeImp.DoomBuilder.UDBScript
|
|||
/// <returns>Found TreeNode or null</returns>
|
||||
private TreeNode FindScriptTreeNode(string name, TreeNode root)
|
||||
{
|
||||
// The "root" node might already be the one we're looking for
|
||||
if (root.Tag is ScriptInfo && ((ScriptInfo)root.Tag).ScriptFile == name)
|
||||
return root;
|
||||
|
||||
foreach (TreeNode node in root.Nodes)
|
||||
{
|
||||
if (node.Tag is ScriptInfo && ((ScriptInfo)node.Tag).ScriptFile == name)
|
||||
|
|
Loading…
Reference in a new issue