mirror of
https://github.com/ppy/osu
synced 2025-01-20 13:00:54 +00:00
Prevent ruleset input managers from reading duplicate bindings
This commit is contained in:
parent
90c44cee54
commit
639c96e60c
@ -137,7 +137,7 @@ namespace osu.Game.Input
|
||||
/// </summary>
|
||||
/// <param name="keyBindings">The <see cref="RealmKeyBinding"/>s to de-duplicate.</param>
|
||||
/// <returns>Whether any bindings have been cleared.</returns>
|
||||
public static bool ClearDuplicateBindings(IQueryable<RealmKeyBinding> keyBindings)
|
||||
public static bool ClearDuplicateBindings(IQueryable<IKeyBinding> keyBindings)
|
||||
{
|
||||
bool anyRemoved = false;
|
||||
|
||||
|
@ -218,6 +218,7 @@ namespace osu.Game.Rulesets.UI
|
||||
base.ReloadMappings(realmKeyBindings);
|
||||
|
||||
KeyBindings = KeyBindings.Where(b => RealmKeyBindingStore.CheckValidForGameplay(b.KeyCombination)).ToList();
|
||||
RealmKeyBindingStore.ClearDuplicateBindings(KeyBindings.AsQueryable());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user