From 5b40924734e28165bff0693c157648820c955050 Mon Sep 17 00:00:00 2001 From: pointfeev Date: Sat, 5 Mar 2022 21:14:42 -0500 Subject: [PATCH] v3.1.0.1 - Fixed a bug where Paradox Launcher wasn't being ticked as enabled when selected --- CreamInstaller/CreamInstaller.csproj | 2 +- CreamInstaller/ProgramSelection.cs | 2 +- CreamInstaller/SelectForm.cs | 10 ++++++++-- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/CreamInstaller/CreamInstaller.csproj b/CreamInstaller/CreamInstaller.csproj index 7281996..19033c3 100644 --- a/CreamInstaller/CreamInstaller.csproj +++ b/CreamInstaller/CreamInstaller.csproj @@ -5,7 +5,7 @@ True Resources\ini.ico true - 3.1.0.0 + 3.1.0.1 Resources\ini.ico diff --git a/CreamInstaller/ProgramSelection.cs b/CreamInstaller/ProgramSelection.cs index d206712..35c6e18 100644 --- a/CreamInstaller/ProgramSelection.cs +++ b/CreamInstaller/ProgramSelection.cs @@ -81,7 +81,7 @@ internal class ProgramSelection break; } } - Enabled = SelectedDlc.Any(); + Enabled = SelectedDlc.Any() || ExtraDlc.Any(); } internal ProgramSelection() => All.Add(this); diff --git a/CreamInstaller/SelectForm.cs b/CreamInstaller/SelectForm.cs index 48812d2..a2f2fb7 100644 --- a/CreamInstaller/SelectForm.cs +++ b/CreamInstaller/SelectForm.cs @@ -196,7 +196,7 @@ internal partial class SelectForm : CustomForm } selection ??= new(); - selection.Enabled = allCheckBox.Checked || selection.SelectedDlc.Any(); + selection.Enabled = allCheckBox.Checked || selection.SelectedDlc.Any() || selection.ExtraDlc.Any(); selection.Usable = true; selection.Id = appId; selection.Name = name; @@ -294,7 +294,7 @@ internal partial class SelectForm : CustomForm } selection ??= new(); - selection.Enabled = allCheckBox.Checked || selection.SelectedDlc.Any(); + selection.Enabled = allCheckBox.Checked || selection.SelectedDlc.Any() || selection.ExtraDlc.Any(); selection.Usable = true; selection.Id = @namespace; selection.Name = name; @@ -472,6 +472,12 @@ internal partial class SelectForm : CustomForm if (selection is not null) selection.ToggleDlc(node.Name, node.Checked); } + else + { + ProgramSelection selection = ProgramSelection.FromId(node.Name); + if (selection is not null) + selection.Enabled = node.Checked; + } } internal List TreeNodes => GatherTreeNodes(selectionTreeView.Nodes);