From 1faa789f482ec738beebbb63f489b1e80ee69f47 Mon Sep 17 00:00:00 2001 From: yasirkula Date: Sat, 2 Nov 2024 14:56:30 +0300 Subject: [PATCH] Removed an unused variable --- Plugins/AssetUsageDetector/Editor/SearchResult.cs | 2 +- Plugins/AssetUsageDetector/Editor/SearchResultTreeView.cs | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/Plugins/AssetUsageDetector/Editor/SearchResult.cs b/Plugins/AssetUsageDetector/Editor/SearchResult.cs index e9b6641..543d7f5 100644 --- a/Plugins/AssetUsageDetector/Editor/SearchResult.cs +++ b/Plugins/AssetUsageDetector/Editor/SearchResult.cs @@ -881,7 +881,7 @@ namespace AssetUsageDetectorNamespace if( shouldUpdateInitialTreeViewNodeId ) treeViewState.initialNodeId = searchResult.nextTreeViewId; - treeView = new SearchResultTreeView( treeViewState, references, ( Type == GroupType.UnusedObjects ) ? SearchResultTreeView.TreeType.UnusedObjects : SearchResultTreeView.TreeType.Normal, searchResult != null ? searchResult.UsedObjects : null, searchResult != null && searchResult.SearchParameters.hideDuplicateRows, searchResult != null && searchResult.SearchParameters.hideReduntantPrefabVariantLinks, true ); + treeView = new SearchResultTreeView( treeViewState, references, ( Type == GroupType.UnusedObjects ) ? SearchResultTreeView.TreeType.UnusedObjects : SearchResultTreeView.TreeType.Normal, searchResult != null ? searchResult.UsedObjects : null, searchResult != null && searchResult.SearchParameters.hideDuplicateRows, true ); if( isFirstInitialization ) { diff --git a/Plugins/AssetUsageDetector/Editor/SearchResultTreeView.cs b/Plugins/AssetUsageDetector/Editor/SearchResultTreeView.cs index cbb68fa..20c6c3f 100644 --- a/Plugins/AssetUsageDetector/Editor/SearchResultTreeView.cs +++ b/Plugins/AssetUsageDetector/Editor/SearchResultTreeView.cs @@ -124,7 +124,6 @@ namespace AssetUsageDetectorNamespace private readonly TreeType treeType; private readonly bool hideDuplicateRows; - private readonly bool hideReduntantPrefabVariantLinks; private bool isSearching; @@ -164,13 +163,12 @@ namespace AssetUsageDetectorNamespace [System.Obsolete] private new string searchString { get; } [System.Obsolete] private new bool hasSearch { get; } - public SearchResultTreeView( SearchResultTreeViewState state, List references, TreeType treeType, HashSet usedObjectsSet, bool hideDuplicateRows, bool hideReduntantPrefabVariantLinks, bool usesExternalScrollView ) : base( state ) + public SearchResultTreeView( SearchResultTreeViewState state, List references, TreeType treeType, HashSet usedObjectsSet, bool hideDuplicateRows, bool usesExternalScrollView ) : base( state ) { this.state = state; this.references = references; this.treeType = treeType; this.hideDuplicateRows = hideDuplicateRows; - this.hideReduntantPrefabVariantLinks = hideReduntantPrefabVariantLinks; highlightedSearchTextColor = ""; @@ -1158,7 +1156,7 @@ namespace AssetUsageDetectorNamespace if( selectedNodes.Count > 0 ) { - SearchResultTreeView isolatedTreeView = new SearchResultTreeView( new SearchResultTreeViewState(), selectedNodes, TreeType.IsolatedView, null, hideDuplicateRows, hideReduntantPrefabVariantLinks, false ); + SearchResultTreeView isolatedTreeView = new SearchResultTreeView( new SearchResultTreeViewState(), selectedNodes, TreeType.IsolatedView, null, hideDuplicateRows, false ); isolatedTreeView.ExpandMainReferences(); SearchResultTreeViewIsolatedView.Show( new Vector2( EditorWindow.focusedWindow.position.width, Mathf.Max( isolatedTreeView.totalHeight, EditorGUIUtility.singleLineHeight * 5f ) + 1f ), isolatedTreeView, new GUIContent( selectedNodes[0].Label + ( selectedNodes.Count <= 1 ? "" : ( " (and " + ( selectedNodes.Count - 1 ) + " more)" ) ) ) );