2019-03-04 04:24:19 +00: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-09-24 15:57:44 +00:00
|
|
|
|
|
|
|
using osu.Framework.Graphics;
|
|
|
|
using osu.Framework.Graphics.Containers;
|
|
|
|
using osu.Game.Graphics.Sprites;
|
2018-11-22 01:25:30 +00:00
|
|
|
using osuTK.Graphics;
|
2018-09-24 15:57:44 +00:00
|
|
|
|
2018-09-24 19:21:48 +00:00
|
|
|
namespace osu.Game.Tournament.Screens.Ladder.Components
|
2018-09-24 15:57:44 +00:00
|
|
|
{
|
|
|
|
public class DrawableTournamentGrouping : CompositeDrawable
|
|
|
|
{
|
2018-09-24 17:31:48 +00:00
|
|
|
public DrawableTournamentGrouping(TournamentGrouping grouping, bool losers = false)
|
2018-09-24 15:57:44 +00:00
|
|
|
{
|
|
|
|
AutoSizeAxes = Axes.Both;
|
|
|
|
InternalChild = new FillFlowContainer
|
|
|
|
{
|
|
|
|
Direction = FillDirection.Vertical,
|
|
|
|
AutoSizeAxes = Axes.Both,
|
|
|
|
Children = new Drawable[]
|
|
|
|
{
|
|
|
|
new OsuSpriteText
|
|
|
|
{
|
2018-10-12 22:10:13 +00:00
|
|
|
Text = grouping.Description.Value.ToUpper(),
|
2018-10-17 17:17:54 +00:00
|
|
|
Colour = Color4.Black,
|
2018-09-24 15:57:44 +00:00
|
|
|
Origin = Anchor.TopCentre,
|
|
|
|
Anchor = Anchor.TopCentre
|
|
|
|
},
|
|
|
|
new OsuSpriteText
|
|
|
|
{
|
2018-09-24 17:31:48 +00:00
|
|
|
Text = ((losers ? "Losers " : "") + grouping.Name).ToUpper(),
|
2018-09-24 15:57:44 +00:00
|
|
|
Font = "Exo2.0-Bold",
|
2018-10-17 17:17:54 +00:00
|
|
|
Colour = Color4.Black,
|
2018-09-24 15:57:44 +00:00
|
|
|
Origin = Anchor.TopCentre,
|
|
|
|
Anchor = Anchor.TopCentre
|
|
|
|
},
|
|
|
|
}
|
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|