1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-10 10:22:55 +08:00
osu-lazer/osu.Game/Overlays/Changelog/Header/BreadcrumbRelease.cs

35 lines
917 B
C#
Raw Normal View History

2019-05-12 23:36:05 +08:00
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
2018-07-17 05:50:22 +08:00
using osu.Framework.Graphics.Colour;
namespace osu.Game.Overlays.Changelog.Header
{
public class BreadcrumbRelease : Breadcrumb
2018-07-17 05:50:22 +08:00
{
2018-07-17 21:01:53 +08:00
private const float transition_duration = 125;
2018-07-17 05:50:22 +08:00
public BreadcrumbRelease(ColourInfo badgeColour, string displayText)
2019-05-12 23:36:05 +08:00
: base(badgeColour, displayText)
2018-07-17 05:50:22 +08:00
{
2018-07-19 01:32:15 +08:00
Text.Font = "Exo2.0-Bold";
Text.Y = 20;
Text.Alpha = 0;
2018-07-17 05:50:22 +08:00
}
public void ShowBuild(string displayText = null)
2018-07-17 05:50:22 +08:00
{
ShowText(transition_duration, displayText);
2018-07-20 06:52:50 +08:00
IsActivated = true;
2018-07-17 05:50:22 +08:00
}
public override void Deactivate()
{
if (!IsActivated)
return;
2018-07-17 21:01:53 +08:00
HideText(transition_duration);
2018-07-17 05:50:22 +08:00
}
}
}