Improve input detection to not make cursor flicker on combined input

This commit is contained in:
Salman Ahmed 2022-10-20 03:45:17 +03:00
parent 4bf4938b72
commit 39650717ea

View File

@ -277,14 +277,19 @@ namespace osu.Game.Graphics.Cursor
{
switch (e)
{
case MouseEvent:
case MouseDownEvent:
case MouseMoveEvent:
lastInputWasMouseSource.Value = true;
return false;
default:
case KeyDownEvent keyDown when !keyDown.Repeat:
case JoystickPressEvent:
case MidiDownEvent:
lastInputWasMouseSource.Value = false;
return false;
}
return false;
}
}