mirror of https://github.com/ppy/osu
Rename {Drawable -> Clickable}Avatar
This commit is contained in:
parent
3e06f592a1
commit
0b42b4b955
|
@ -78,7 +78,7 @@ private void load(IAPIProvider api, OsuColour colour, ScoreManager scoreManager)
|
|||
|
||||
statisticsLabels = GetStatistics(score).Select(s => new ScoreComponentLabel(s)).ToList();
|
||||
|
||||
DrawableAvatar innerAvatar;
|
||||
ClickableAvatar innerAvatar;
|
||||
|
||||
Children = new Drawable[]
|
||||
{
|
||||
|
@ -115,7 +115,7 @@ private void load(IAPIProvider api, OsuColour colour, ScoreManager scoreManager)
|
|||
Children = new[]
|
||||
{
|
||||
avatar = new DelayedLoadWrapper(
|
||||
innerAvatar = new DrawableAvatar(user)
|
||||
innerAvatar = new ClickableAvatar(user)
|
||||
{
|
||||
RelativeSizeAxes = Axes.Both,
|
||||
CornerRadius = corner_radius,
|
||||
|
|
|
@ -25,7 +25,7 @@ public PrivateChannelTabItem(Channel value)
|
|||
if (value.Type != ChannelType.PM)
|
||||
throw new ArgumentException("Argument value needs to have the targettype user!");
|
||||
|
||||
DrawableAvatar avatar;
|
||||
ClickableAvatar avatar;
|
||||
|
||||
AddRange(new Drawable[]
|
||||
{
|
||||
|
@ -48,7 +48,7 @@ public PrivateChannelTabItem(Channel value)
|
|||
Anchor = Anchor.Centre,
|
||||
Origin = Anchor.Centre,
|
||||
Masking = true,
|
||||
Child = new DelayedLoadWrapper(avatar = new DrawableAvatar(value.Users.First())
|
||||
Child = new DelayedLoadWrapper(avatar = new ClickableAvatar(value.Users.First())
|
||||
{
|
||||
RelativeSizeAxes = Axes.Both,
|
||||
OpenOnClick = { Value = false },
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
namespace osu.Game.Users.Drawables
|
||||
{
|
||||
[LongRunningLoad]
|
||||
public class DrawableAvatar : Container
|
||||
public class ClickableAvatar : Container
|
||||
{
|
||||
/// <summary>
|
||||
/// Whether to open the user's profile when clicked.
|
||||
|
@ -27,10 +27,11 @@ public class DrawableAvatar : Container
|
|||
private OsuGame game { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// An avatar for specified user.
|
||||
/// A clickable avatar for specified user, with UI sounds included.
|
||||
/// If <see cref="OpenOnClick"/> is <c>true</c>, clicking will open the user's profile.
|
||||
/// </summary>
|
||||
/// <param name="user">The user. A null value will get a placeholder avatar.</param>
|
||||
public DrawableAvatar(User user = null)
|
||||
public ClickableAvatar(User user = null)
|
||||
{
|
||||
this.user = user;
|
||||
}
|
|
@ -65,7 +65,7 @@ protected override Drawable CreateDrawable(User user)
|
|||
if (user == null && !ShowGuestOnNull)
|
||||
return null;
|
||||
|
||||
var avatar = new DrawableAvatar(user)
|
||||
var avatar = new ClickableAvatar(user)
|
||||
{
|
||||
RelativeSizeAxes = Axes.Both,
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue