mirror of
https://github.com/osukey/osukey.git
synced 2025-08-06 08:03:52 +09:00
Merge pull request #10759 from Joehuu/disable-watching-yourself
This commit is contained in:
@ -110,7 +110,11 @@ namespace osu.Game.Overlays.Dashboard
|
|||||||
User = user;
|
User = user;
|
||||||
|
|
||||||
AutoSizeAxes = Axes.Both;
|
AutoSizeAxes = Axes.Both;
|
||||||
|
}
|
||||||
|
|
||||||
|
[BackgroundDependencyLoader]
|
||||||
|
private void load(IAPIProvider api)
|
||||||
|
{
|
||||||
InternalChildren = new Drawable[]
|
InternalChildren = new Drawable[]
|
||||||
{
|
{
|
||||||
new FillFlowContainer
|
new FillFlowContainer
|
||||||
@ -121,7 +125,7 @@ namespace osu.Game.Overlays.Dashboard
|
|||||||
Width = 290,
|
Width = 290,
|
||||||
Children = new Drawable[]
|
Children = new Drawable[]
|
||||||
{
|
{
|
||||||
new UserGridPanel(user)
|
new UserGridPanel(User)
|
||||||
{
|
{
|
||||||
RelativeSizeAxes = Axes.X,
|
RelativeSizeAxes = Axes.X,
|
||||||
Anchor = Anchor.TopCentre,
|
Anchor = Anchor.TopCentre,
|
||||||
@ -133,7 +137,8 @@ namespace osu.Game.Overlays.Dashboard
|
|||||||
Text = "Watch",
|
Text = "Watch",
|
||||||
Anchor = Anchor.TopCentre,
|
Anchor = Anchor.TopCentre,
|
||||||
Origin = Anchor.TopCentre,
|
Origin = Anchor.TopCentre,
|
||||||
Action = () => game?.PerformFromScreen(s => s.Push(new Spectator(user)))
|
Action = () => game?.PerformFromScreen(s => s.Push(new Spectator(User))),
|
||||||
|
Enabled = { Value = User.Id != api.LocalUser.Value.Id }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
Reference in New Issue
Block a user