mirror of
https://github.com/ppy/osu.git
synced 2024-12-15 10:42:54 +08:00
Fixed typo, made mod select take focus when visible
This commit is contained in:
parent
d82b67ee9b
commit
d1af050355
@ -137,7 +137,7 @@ namespace osu.Game.Modes
|
||||
switch (mode)
|
||||
{
|
||||
case PlayMode.Osu:
|
||||
return "You don't need to click. \nGive your clicking/tapping finger a break from the heat of things.";
|
||||
return "You don't need to click.\nGive your clicking/tapping finger a break from the heat of things.";
|
||||
|
||||
case PlayMode.Taiko:
|
||||
return @"Relax! You will no longer get dizzyfied by ninja-like spinners, demanding drumrolls or unexpected katu's.";
|
||||
|
@ -15,6 +15,9 @@ using osu.Game.Graphics.Backgrounds;
|
||||
using osu.Game.Graphics.Sprites;
|
||||
using osu.Game.Modes;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Input;
|
||||
using OpenTK.Input;
|
||||
using System.Linq;
|
||||
|
||||
namespace osu.Game.Overlays.Mods
|
||||
{
|
||||
@ -84,6 +87,28 @@ namespace osu.Game.Overlays.Mods
|
||||
}
|
||||
}
|
||||
|
||||
public override bool RequestingFocus => State == Visibility.Visible;
|
||||
|
||||
protected override bool OnFocus(InputState state) => true;
|
||||
protected override void OnFocusLost(InputState state)
|
||||
{
|
||||
if (state.Keyboard.Keys.Contains(Key.Escape))
|
||||
Hide();
|
||||
base.OnFocusLost(state);
|
||||
}
|
||||
|
||||
protected override void PopIn()
|
||||
{
|
||||
base.PopIn();
|
||||
Schedule(TriggerFocusContention);
|
||||
}
|
||||
|
||||
protected override void PopOut()
|
||||
{
|
||||
base.PopOut();
|
||||
TriggerFocusLost();
|
||||
}
|
||||
|
||||
protected override void TransitionIn()
|
||||
{
|
||||
rankedMultiplerContainer.MoveToX(0, ranked_multiplier_duration, EasingTypes.OutQuint);
|
||||
|
Loading…
Reference in New Issue
Block a user