mirror of
https://github.com/ppy/osu.git
synced 2024-11-06 06:57:39 +08:00
Allow setting the displayed text on LoginPlaceholder
This commit is contained in:
parent
e1eda89ea6
commit
e9a5298484
@ -151,7 +151,7 @@ namespace osu.Game.Online.Leaderboards
|
||||
break;
|
||||
|
||||
case PlaceholderState.NotLoggedIn:
|
||||
replacePlaceholder(new LoginPlaceholder());
|
||||
replacePlaceholder(new LoginPlaceholder(@"Please sign in to view online leaderboards!"));
|
||||
break;
|
||||
|
||||
case PlaceholderState.NotSupporter:
|
||||
|
@ -32,7 +32,7 @@ namespace osu.Game.Online
|
||||
{
|
||||
RelativeSizeAxes = Axes.Both,
|
||||
Alpha = 0,
|
||||
Child = placeholder = new LoginPlaceholder()
|
||||
Child = placeholder = new LoginPlaceholder(placeholder_message)
|
||||
},
|
||||
};
|
||||
}
|
||||
|
@ -14,7 +14,7 @@ namespace osu.Game.Online.Placeholders
|
||||
[Resolved(CanBeNull = true)]
|
||||
private LoginOverlay login { get; set; }
|
||||
|
||||
public LoginPlaceholder()
|
||||
public LoginPlaceholder(string actionMessage)
|
||||
{
|
||||
AddIcon(FontAwesome.Solid.UserLock, cp =>
|
||||
{
|
||||
@ -22,7 +22,7 @@ namespace osu.Game.Online.Placeholders
|
||||
cp.Padding = new MarginPadding { Right = 10 };
|
||||
});
|
||||
|
||||
AddText(@"Please sign in to view online leaderboards!");
|
||||
AddText(actionMessage);
|
||||
}
|
||||
|
||||
protected override bool OnMouseDown(MouseDownEvent e)
|
||||
|
Loading…
Reference in New Issue
Block a user