Skip to content

Commit

Permalink
Don't say "1 new mods, show them"
Browse files Browse the repository at this point in the history
  • Loading branch information
HebaruSan committed Nov 24, 2017
1 parent 721e4e4 commit 5d6888d
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions ConsoleUI/ModListScreen.cs
Original file line number Diff line number Diff line change
Expand Up @@ -383,15 +383,21 @@ private bool UpdateRegistry()
}
}
});
if (recent.Count > 0 && RaiseYesNoDialog(
$"{recent.Count} new mods available since last update. Show them?")) {
if (recent.Count > 0 && RaiseYesNoDialog(newModPrompt(recent.Count))) {
searchBox.Clear();
moduleList.FilterString = searchBox.Value = "~n";
}
RefreshList();
return true;
}

private string newModPrompt(int howMany)
{
return howMany == 1
? $"{howMany} new mod available since last update. Show it?"
: $"{howMany} new mods available since last update. Show them?";
}

private bool ScanForMods()
{
try {
Expand Down

0 comments on commit 5d6888d

Please sign in to comment.