mirror of
https://github.com/ppy/osu.git
synced 2024-09-29 14:47:24 +08:00
29 lines
789 B
C#
29 lines
789 B
C#
|
// Copyright (c) 2007-2017 ppy Pty Ltd <contact@ppy.sh>.
|
|||
|
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
|||
|
|
|||
|
using osu.Framework.Allocation;
|
|||
|
using osu.Framework.Graphics.Sprites;
|
|||
|
using osu.Framework.Graphics.Textures;
|
|||
|
using osu.Game.Database;
|
|||
|
|
|||
|
namespace osu.Game
|
|||
|
{
|
|||
|
public class BeatmapSetCover : Sprite
|
|||
|
{
|
|||
|
private readonly BeatmapSetInfo set;
|
|||
|
public BeatmapSetCover(BeatmapSetInfo set)
|
|||
|
{
|
|||
|
this.set = set;
|
|||
|
}
|
|||
|
|
|||
|
[BackgroundDependencyLoader]
|
|||
|
private void load(TextureStore textures)
|
|||
|
{
|
|||
|
string resource = set.OnlineInfo.Covers.Cover;
|
|||
|
|
|||
|
if (resource != null)
|
|||
|
Texture = textures.Get(resource);
|
|||
|
}
|
|||
|
}
|
|||
|
}
|