mirror of
https://github.com/ppy/osu.git
synced 2026-06-04 13:44:26 +08:00
Fix Ctrl+Enter behaviour regression
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
using System.Linq;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Framework.Input.Events;
|
||||
using osu.Framework.Screens;
|
||||
using osu.Game.Graphics;
|
||||
using osu.Game.Screens.Play;
|
||||
@@ -49,6 +50,20 @@ namespace osu.Game.Screens.Select
|
||||
}
|
||||
}
|
||||
|
||||
protected override bool OnKeyDown(KeyDownEvent e)
|
||||
{
|
||||
switch (e.Key)
|
||||
{
|
||||
case Key.Enter:
|
||||
// this is a special hard-coded case; we can't rely on OnPressed (of SongSelect) as GlobalActionContainer is
|
||||
// matching with exact modifier consideration (so Ctrl+Enter would be ignored).
|
||||
FinaliseSelection();
|
||||
return true;
|
||||
}
|
||||
|
||||
return base.OnKeyDown(e);
|
||||
}
|
||||
|
||||
protected override bool OnStart()
|
||||
{
|
||||
if (player != null) return false;
|
||||
|
||||
Reference in New Issue
Block a user