From 90477e3788fdeccc88e5181ce7f2851cbebca609 Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Fri, 22 Oct 2021 19:12:37 +0900 Subject: [PATCH] Remove unused `BeatmapTypeInfo` class Helps reduce the scope of upcoming changes. --- .../OnlinePlay/Components/BeatmapTypeInfo.cs | 72 ------------------- 1 file changed, 72 deletions(-) delete mode 100644 osu.Game/Screens/OnlinePlay/Components/BeatmapTypeInfo.cs diff --git a/osu.Game/Screens/OnlinePlay/Components/BeatmapTypeInfo.cs b/osu.Game/Screens/OnlinePlay/Components/BeatmapTypeInfo.cs deleted file mode 100644 index 3aa13458a4..0000000000 --- a/osu.Game/Screens/OnlinePlay/Components/BeatmapTypeInfo.cs +++ /dev/null @@ -1,72 +0,0 @@ -// Copyright (c) ppy Pty Ltd . Licensed under the MIT Licence. -// See the LICENCE file in the repository root for full licence text. - -using System.Linq; -using osu.Framework.Allocation; -using osu.Framework.Graphics; -using osu.Framework.Graphics.Containers; -using osu.Game.Graphics; -using osu.Game.Graphics.Containers; -using osuTK; - -namespace osu.Game.Screens.OnlinePlay.Components -{ - public class BeatmapTypeInfo : OnlinePlayComposite - { - private LinkFlowContainer beatmapAuthor; - - public BeatmapTypeInfo() - { - AutoSizeAxes = Axes.Both; - } - - [BackgroundDependencyLoader] - private void load() - { - InternalChild = new FillFlowContainer - { - AutoSizeAxes = Axes.Both, - Direction = FillDirection.Horizontal, - LayoutDuration = 100, - Spacing = new Vector2(5, 0), - Children = new Drawable[] - { - new ModeTypeInfo(), - new Container - { - AutoSizeAxes = Axes.X, - Height = 30, - Margin = new MarginPadding { Left = 5 }, - Children = new Drawable[] - { - new BeatmapTitle(), - beatmapAuthor = new LinkFlowContainer(s => s.Font = s.Font.With(size: 14)) - { - Anchor = Anchor.BottomLeft, - Origin = Anchor.BottomLeft, - AutoSizeAxes = Axes.Both - }, - }, - }, - } - }; - - Playlist.CollectionChanged += (_, __) => updateInfo(); - - updateInfo(); - } - - private void updateInfo() - { - beatmapAuthor.Clear(); - - var beatmap = Playlist.FirstOrDefault()?.Beatmap; - - if (beatmap != null) - { - beatmapAuthor.AddText("mapped by ", s => s.Colour = OsuColour.Gray(0.8f)); - beatmapAuthor.AddUserLink(beatmap.Value.Metadata.Author); - } - } - } -}