Skip to content

Commit

Permalink
refactor : asset bundle reporter
Browse files Browse the repository at this point in the history
  • Loading branch information
gmhevinci committed Dec 27, 2023
1 parent cbdb84a commit 9ebe92f
Showing 1 changed file with 0 additions and 25 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,6 @@ private enum EViewMode
/// 资源包视图
/// </summary>
BundleView,

/// <summary>
/// 冗余资源试图
/// </summary>
Redundancy,
}

private ToolbarMenu _viewModeMenu;
Expand Down Expand Up @@ -75,7 +70,6 @@ public void CreateGUI()
_viewModeMenu.menu.AppendAction(EViewMode.Summary.ToString(), ViewModeMenuAction0, ViewModeMenuFun0);
_viewModeMenu.menu.AppendAction(EViewMode.AssetView.ToString(), ViewModeMenuAction1, ViewModeMenuFun1);
_viewModeMenu.menu.AppendAction(EViewMode.BundleView.ToString(), ViewModeMenuAction2, ViewModeMenuFun2);
_viewModeMenu.menu.AppendAction(EViewMode.Redundancy.ToString(), ViewModeMenuAction3, ViewModeMenuFun3);

// 搜索栏
var searchField = root.Q<ToolbarSearchField>("SearchField");
Expand Down Expand Up @@ -166,18 +160,6 @@ private void ViewModeMenuAction2(DropdownMenuAction action)
_bundleListViewer.AttachParent(root);
}
}
private void ViewModeMenuAction3(DropdownMenuAction action)
{
if (_viewMode != EViewMode.Redundancy)
{
_viewMode = EViewMode.Redundancy;
VisualElement root = this.rootVisualElement;
_viewModeMenu.text = EViewMode.Redundancy.ToString();
_summaryViewer.DetachParent();
_assetListViewer.DetachParent();
_bundleListViewer.DetachParent();
}
}
private DropdownMenuAction.Status ViewModeMenuFun0(DropdownMenuAction action)
{
if (_viewMode == EViewMode.Summary)
Expand All @@ -199,13 +181,6 @@ private DropdownMenuAction.Status ViewModeMenuFun2(DropdownMenuAction action)
else
return DropdownMenuAction.Status.Normal;
}
private DropdownMenuAction.Status ViewModeMenuFun3(DropdownMenuAction action)
{
if (_viewMode == EViewMode.Redundancy)
return DropdownMenuAction.Status.Checked;
else
return DropdownMenuAction.Status.Normal;
}
}
}
#endif

0 comments on commit 9ebe92f

Please sign in to comment.