2019-01-24 17:43:03 +09: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-04-13 18:19:50 +09:00
|
|
|
|
|
|
|
|
|
using osu.Framework.Allocation;
|
|
|
|
|
using osu.Framework.Graphics;
|
2019-03-27 19:29:27 +09:00
|
|
|
|
using osu.Framework.Graphics.Sprites;
|
2018-04-13 18:19:50 +09:00
|
|
|
|
using osu.Game.Graphics;
|
2024-03-31 01:30:08 +03:00
|
|
|
|
using osu.Game.Graphics.Sprites;
|
2018-11-20 16:51:59 +09:00
|
|
|
|
using osuTK;
|
2018-04-13 18:19:50 +09:00
|
|
|
|
|
|
|
|
|
namespace osu.Game.Screens.Play.Break
|
|
|
|
|
{
|
2024-03-31 01:30:08 +03:00
|
|
|
|
public partial class GlowIcon : GlowingDrawable
|
2018-04-13 18:19:50 +09:00
|
|
|
|
{
|
2024-03-31 01:30:08 +03:00
|
|
|
|
private SpriteIcon icon = null!;
|
2018-04-13 18:19:50 +09:00
|
|
|
|
|
2024-03-31 01:30:08 +03:00
|
|
|
|
public IconUsage Icon
|
2018-04-13 18:19:50 +09:00
|
|
|
|
{
|
2024-03-31 01:30:08 +03:00
|
|
|
|
set => icon.Icon = value;
|
|
|
|
|
get => icon.Icon;
|
2018-04-13 18:19:50 +09:00
|
|
|
|
}
|
|
|
|
|
|
2024-03-31 01:30:08 +03:00
|
|
|
|
public new Vector2 Size
|
2018-04-13 18:19:50 +09:00
|
|
|
|
{
|
2024-03-31 01:30:08 +03:00
|
|
|
|
set => icon.Size = value;
|
|
|
|
|
get => icon.Size;
|
2018-04-13 18:19:50 +09:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public GlowIcon()
|
|
|
|
|
{
|
|
|
|
|
RelativePositionAxes = Axes.X;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
[BackgroundDependencyLoader]
|
|
|
|
|
private void load(OsuColour colours)
|
|
|
|
|
{
|
2024-03-31 01:30:08 +03:00
|
|
|
|
GlowColour = colours.BlueLighter;
|
2018-04-13 18:19:50 +09:00
|
|
|
|
}
|
2024-03-31 01:30:08 +03:00
|
|
|
|
|
|
|
|
|
protected override Drawable CreateDrawable() => icon = new SpriteIcon
|
|
|
|
|
{
|
|
|
|
|
Origin = Anchor.Centre,
|
|
|
|
|
Anchor = Anchor.Centre,
|
|
|
|
|
Shadow = false,
|
|
|
|
|
};
|
2018-04-13 18:19:50 +09:00
|
|
|
|
}
|
|
|
|
|
}
|