From 32f7f1ade790204a648d11f88bb61e34894e1d5e Mon Sep 17 00:00:00 2001 From: Joonas Rikkonen Date: Sat, 18 May 2019 17:46:53 +0300 Subject: [PATCH] (59836c1e0) Updated: EnglishVanilla --- .../Source/Screens/ServerListScreen.cs | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/Barotrauma/BarotraumaClient/Source/Screens/ServerListScreen.cs b/Barotrauma/BarotraumaClient/Source/Screens/ServerListScreen.cs index 0344ba7c1..1f146ab06 100644 --- a/Barotrauma/BarotraumaClient/Source/Screens/ServerListScreen.cs +++ b/Barotrauma/BarotraumaClient/Source/Screens/ServerListScreen.cs @@ -218,6 +218,22 @@ namespace Barotrauma return true; } + private bool RefreshJoinButtonState(GUIComponent component, object obj) + { + if (obj == null || waitingForRefresh) { return false; } + + if (!string.IsNullOrWhiteSpace(clientNameBox.Text) && !string.IsNullOrWhiteSpace(ipBox.Text)) + { + joinButton.Enabled = true; + } + else + { + joinButton.Enabled = false; + } + + return true; + } + private bool SelectServer(GUIComponent component, object obj) { if (obj == null || waitingForRefresh) { return false; }