2021-01-22 03:02:54 +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.
|
|
|
|
|
|
|
|
|
|
using osu.Framework.Allocation;
|
|
|
|
|
using osu.Framework.Bindables;
|
|
|
|
|
using osu.Framework.Graphics.Sprites;
|
|
|
|
|
using osu.Game.Users;
|
|
|
|
|
|
|
|
|
|
namespace osu.Game.Overlays.Profile.Header.Components
|
|
|
|
|
{
|
|
|
|
|
public class MappingSubscribersButton : ProfileHeaderStatisticsButton
|
|
|
|
|
{
|
|
|
|
|
public readonly Bindable<User> User = new Bindable<User>();
|
|
|
|
|
|
|
|
|
|
public override string TooltipText => "mapping subscribers";
|
|
|
|
|
|
2021-01-22 03:47:44 +08:00
|
|
|
|
protected override IconUsage CreateIcon => FontAwesome.Solid.Bell;
|
2021-01-22 03:02:54 +08:00
|
|
|
|
|
|
|
|
|
[BackgroundDependencyLoader]
|
|
|
|
|
private void load()
|
|
|
|
|
{
|
|
|
|
|
User.BindValueChanged(user => SetValue(user.NewValue?.MappingFollowerCount ?? 0), true);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|