Skip to content

Commit

Permalink
chore(ModInstaller): "Enable only this mod" checkbox defaults to off …
Browse files Browse the repository at this point in the history
…for multi mod characters
  • Loading branch information
Jorixon committed May 5, 2024
1 parent 461a91f commit 9aa90a9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion src/GIMI-ModManager.WinUI/ViewModels/ModInstallerVM.cs
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ public async Task InitializeAsync(ICharacterModList characterModList, DirectoryI
.ReadOrCreateSettingAsync<ModInstallerSettings>(ModInstallerSettings.Key);


EnableThisMod = installerSettings.EnableModOnInstall;
EnableThisMod = !_characterModList.Character.IsMultiMod && installerSettings.EnableModOnInstall;
AlwaysOnTop = installerSettings.ModInstallerWindowOnTop;

await Task.Run(() =>
Expand Down Expand Up @@ -737,6 +737,8 @@ private void ErrorOccurred(Exception e)
[RelayCommand]
private async Task EnableOnlyToggleAsync()
{
EnableThisMod = !EnableThisMod;

var settings = await _localSettingsService
.ReadOrCreateSettingAsync<ModInstallerSettings>(ModInstallerSettings.Key)
.ConfigureAwait(false);
Expand Down
2 changes: 1 addition & 1 deletion src/GIMI-ModManager.WinUI/Views/ModInstallerPage.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@
Margin="8,0"
Command="{x:Bind ViewModel.EnableOnlyToggleCommand}"
Content="Enable this mod and disable others?"
IsChecked="{x:Bind ViewModel.EnableThisMod, Mode=TwoWay}"
IsChecked="{x:Bind ViewModel.EnableThisMod, Mode=OneWay}"
ToolTipService.ToolTip="This will enable this mod and disable all other mods. If a character then it will only disable for that characters skin" />

<Button
Expand Down

0 comments on commit 9aa90a9

Please sign in to comment.