2021-01-21 22:02:54 +03: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;
|
2021-06-25 19:10:04 +02:00
|
|
|
|
using osu.Framework.Localisation;
|
2021-07-17 15:18:45 +02:00
|
|
|
|
using osu.Game.Resources.Localisation.Web;
|
2021-01-21 22:02:54 +03:00
|
|
|
|
|
|
|
|
|
namespace osu.Game.Overlays.Profile.Header.Components
|
|
|
|
|
{
|
2022-11-24 14:32:20 +09:00
|
|
|
|
public partial class MappingSubscribersButton : ProfileHeaderStatisticsButton
|
2021-01-21 22:02:54 +03:00
|
|
|
|
{
|
2023-01-10 19:24:54 +01:00
|
|
|
|
public readonly Bindable<UserProfileData?> User = new Bindable<UserProfileData?>();
|
2021-01-21 22:02:54 +03:00
|
|
|
|
|
2021-07-17 15:18:45 +02:00
|
|
|
|
public override LocalisableString TooltipText => FollowsStrings.MappingFollowers;
|
2021-01-21 22:02:54 +03:00
|
|
|
|
|
2021-01-21 23:39:19 +03:00
|
|
|
|
protected override IconUsage Icon => FontAwesome.Solid.Bell;
|
2021-01-21 22:02:54 +03:00
|
|
|
|
|
|
|
|
|
[BackgroundDependencyLoader]
|
|
|
|
|
private void load()
|
|
|
|
|
{
|
2023-01-10 19:24:54 +01:00
|
|
|
|
User.BindValueChanged(user => SetValue(user.NewValue?.User.MappingFollowerCount ?? 0), true);
|
2021-01-21 22:02:54 +03:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|