mirror of
https://github.com/ppy/osu.git
synced 2025-01-19 02:52:54 +08:00
Also handle full mod name (likely irrelevant but might as well)
This commit is contained in:
parent
2ef8720590
commit
9a0356919c
@ -592,7 +592,7 @@ namespace osu.Game.Overlays.Mods
|
||||
|
||||
//matchingMod ensures that if an exact mod acronym is typed, it will be selected when Select is pressed (as opposed to being prioritized in arbitrary column order)
|
||||
ModState? firstMod = columnFlow.Columns.OfType<ModColumn>().FirstOrDefault(m => m.IsPresent)?.AvailableMods.FirstOrDefault(x => x.Visible);
|
||||
ModState? matchingMod = columnFlow.Columns.OfType<ModColumn>().SelectMany(m => m.AvailableMods).FirstOrDefault(x => x.Mod.Acronym.Equals(SearchTerm, StringComparison.OrdinalIgnoreCase));
|
||||
ModState? matchingMod = columnFlow.Columns.OfType<ModColumn>().SelectMany(m => m.AvailableMods).FirstOrDefault(x => x.Mod.Acronym.Equals(SearchTerm, StringComparison.OrdinalIgnoreCase) | x.Mod.Name.Equals(SearchTerm, StringComparison.OrdinalIgnoreCase));
|
||||
|
||||
if (matchingMod is not null)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user