From 092b80ba29fe4c715e741eee5c02f36ce87bc679 Mon Sep 17 00:00:00 2001 From: yasirkula Date: Sat, 7 Oct 2023 20:41:10 +0300 Subject: [PATCH] Fixed some references initially being displayed collapsed after the search --- Plugins/AssetUsageDetector/Editor/SearchResultTreeView.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Plugins/AssetUsageDetector/Editor/SearchResultTreeView.cs b/Plugins/AssetUsageDetector/Editor/SearchResultTreeView.cs index 833c28a..f2cf6d3 100644 --- a/Plugins/AssetUsageDetector/Editor/SearchResultTreeView.cs +++ b/Plugins/AssetUsageDetector/Editor/SearchResultTreeView.cs @@ -966,6 +966,8 @@ namespace AssetUsageDetectorNamespace for( int i = 0; i < item.children.Count; i++ ) shouldExpand |= GetMainReferenceIdsRecursive( item.children[i], ids ); } + else + shouldExpand = true; // No main reference is encountered in this branch; expand the whole branch if( shouldExpand ) ids.Add( item.id );