From 9a5d352e41f2346fa5319630c611551f3dc384c8 Mon Sep 17 00:00:00 2001 From: Zachary Schirm Date: Thu, 8 Sep 2022 18:31:50 -0400 Subject: [PATCH] Disallow saving the game with an empty name field --- OpenRA.Mods.Common/Widgets/Logic/GameSaveBrowserLogic.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/OpenRA.Mods.Common/Widgets/Logic/GameSaveBrowserLogic.cs b/OpenRA.Mods.Common/Widgets/Logic/GameSaveBrowserLogic.cs index ae9aabfef6..12adfa697d 100644 --- a/OpenRA.Mods.Common/Widgets/Logic/GameSaveBrowserLogic.cs +++ b/OpenRA.Mods.Common/Widgets/Logic/GameSaveBrowserLogic.cs @@ -112,6 +112,7 @@ namespace OpenRA.Mods.Common.Widgets.Logic } var saveButton = panel.Get("SAVE_BUTTON"); + saveButton.IsDisabled = () => string.IsNullOrWhiteSpace(saveTextField.Text); saveButton.OnClick = () => { Save(world); }; saveButton.IsVisible = () => true;