1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-15 14:02:55 +08:00

FadeIn/Out

This commit is contained in:
Andrey Zavadskiy 2017-04-03 12:17:53 +03:00
parent e1d3befaed
commit c1b48c6cbf

View File

@ -19,6 +19,9 @@ namespace osu.Game.Modes.UI
{
public abstract class HudOverlay : Container
{
private const int duration = 100;
private readonly Container hud;
public readonly KeyCounterCollection KeyCounter;
public readonly ComboCounter ComboCounter;
public readonly ScoreCounter ScoreCounter;
@ -28,8 +31,6 @@ namespace osu.Game.Modes.UI
private Bindable<bool> showKeyCounter;
private Bindable<bool> showHud;
private readonly Container hud;
private static bool has_shown_notification_once = false;
protected abstract KeyCounterCollection CreateKeyCounter();
@ -90,9 +91,9 @@ namespace osu.Game.Modes.UI
private void hudVisibilityChanged(object sender, EventArgs e)
{
if (showHud)
hud.Show();
hud.FadeIn(duration);
else
hud.Hide();
hud.FadeOut(duration);
}
public void BindProcessor(ScoreProcessor processor)