From d9f9401c5a0fd16287240baf38bab90ac152fbea Mon Sep 17 00:00:00 2001 From: Chandler Cox Date: Wed, 28 Jan 2026 20:04:39 -0600 Subject: [PATCH] Fix tree node not expanding on drag over arrow. --- Source/Editor/GUI/Tree/TreeNode.cs | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/Source/Editor/GUI/Tree/TreeNode.cs b/Source/Editor/GUI/Tree/TreeNode.cs index ed1257819..b0ce8c251 100644 --- a/Source/Editor/GUI/Tree/TreeNode.cs +++ b/Source/Editor/GUI/Tree/TreeNode.cs @@ -1140,8 +1140,11 @@ namespace FlaxEditor.GUI.Tree ParentTree.DraggedOverNode = this; // Expand node if mouse goes over arrow - if (ArrowRect.Contains(location) && HasAnyVisibleChild) + if (ArrowRect.Contains(location) && HasAnyVisibleChild && IsCollapsed) + { Expand(true); + ParentTree?.FlushPendingPerformLayout(); + } result = OnDragEnterHeader(data); } @@ -1172,8 +1175,11 @@ namespace FlaxEditor.GUI.Tree ParentTree.DraggedOverNode = this; // Expand node if mouse goes over arrow - if (ArrowRect.Contains(location) && HasAnyVisibleChild) + if (ArrowRect.Contains(location) && HasAnyVisibleChild && IsCollapsed) + { Expand(true); + ParentTree?.FlushPendingPerformLayout(); + } if (!_isDragOverHeader) result = OnDragEnterHeader(data);