Fix Admin Object tab sorting and search (#28609)

This commit is contained in:
Repo
2024-06-06 18:41:11 +12:00
committed by GitHub
parent d71b88a747
commit 039fd932b2
9 changed files with 230 additions and 40 deletions

View File

@@ -53,6 +53,7 @@ namespace Content.Client.Administration.UI.Tabs.PlayerTab
SearchList.ItemKeyBindDown += (args, data) => OnEntryKeyBindDown?.Invoke(args, data);
RefreshPlayerList(_adminSystem.PlayerList);
}
#region Antag Overlay
@@ -110,7 +111,9 @@ namespace Content.Client.Administration.UI.Tabs.PlayerTab
_players = players;
PlayerCount.Text = $"Players: {_playerMan.PlayerCount}";
var sortedPlayers = new List<PlayerInfo>(players);
var filteredPlayers = players.Where(info => _showDisconnected || info.Connected).ToList();
var sortedPlayers = new List<PlayerInfo>(filteredPlayers);
sortedPlayers.Sort(Compare);
UpdateHeaderSymbols();