From 4cb3e464ac9686aef610d532568a88fa5c4ec3f3 Mon Sep 17 00:00:00 2001 From: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com> Date: Sun, 2 Apr 2023 01:00:48 +1100 Subject: [PATCH] Fix lobby votes (#15041) --- Content.Client/Lobby/LobbyState.cs | 4 ++ Content.Client/Lobby/UI/LobbyGui.xaml | 42 ++++++++++--------- .../Systems/Vote/VoteUIController.cs | 2 + 3 files changed, 28 insertions(+), 20 deletions(-) diff --git a/Content.Client/Lobby/LobbyState.cs b/Content.Client/Lobby/LobbyState.cs index 02efe0daa1..8774242cc6 100644 --- a/Content.Client/Lobby/LobbyState.cs +++ b/Content.Client/Lobby/LobbyState.cs @@ -59,6 +59,8 @@ namespace Content.Client.Lobby _lobby.CharacterSetupState.AddChild(_characterSetup); chatController.SetMainChat(true); + _voteManager.SetPopupContainer(_lobby.VoteContainer); + _characterSetup.CloseButton.OnPressed += _ => { _lobby.SwitchState(LobbyGui.LobbyGuiState.Default); @@ -91,6 +93,8 @@ namespace Content.Client.Lobby _gameTicker.LobbyStatusUpdated -= LobbyStatusUpdated; _gameTicker.LobbyLateJoinStatusUpdated -= LobbyLateJoinStatusUpdated; + _lobby!.VoteContainer.Orphan(); + _lobby!.CharacterPreview.CharacterSetupButton.OnPressed -= OnSetupPressed; _lobby!.ReadyButton.OnPressed -= OnReadyPressed; _lobby!.ReadyButton.OnToggled -= OnReadyToggled; diff --git a/Content.Client/Lobby/UI/LobbyGui.xaml b/Content.Client/Lobby/UI/LobbyGui.xaml index 77c79e96d2..8dbef0632a 100644 --- a/Content.Client/Lobby/UI/LobbyGui.xaml +++ b/Content.Client/Lobby/UI/LobbyGui.xaml @@ -15,26 +15,28 @@ - - - - - - - -