mirror of
https://github.com/ppy/osu.git
synced 2024-12-15 10:42:54 +08:00
Add recent participants
This commit is contained in:
parent
54f087b933
commit
01fa664b7d
@ -66,6 +66,7 @@ namespace osu.Game.Tests.Visual.Multiplayer
|
|||||||
Room.RoomID.Value = 1;
|
Room.RoomID.Value = 1;
|
||||||
Room.Name.Value = "my awesome room";
|
Room.Name.Value = "my awesome room";
|
||||||
Room.Host.Value = new User { Id = 2, Username = "peppy" };
|
Room.Host.Value = new User { Id = 2, Username = "peppy" };
|
||||||
|
Room.RecentParticipants.Add(Room.Host.Value);
|
||||||
Room.Playlist.Add(new PlaylistItem
|
Room.Playlist.Add(new PlaylistItem
|
||||||
{
|
{
|
||||||
Beatmap = { Value = new TestBeatmap(new OsuRuleset().RulesetInfo).BeatmapInfo },
|
Beatmap = { Value = new TestBeatmap(new OsuRuleset().RulesetInfo).BeatmapInfo },
|
||||||
|
@ -35,6 +35,18 @@ namespace osu.Game.Screens.Multi.Components
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private bool showLine = true;
|
||||||
|
|
||||||
|
public bool ShowLine
|
||||||
|
{
|
||||||
|
get => showLine;
|
||||||
|
set
|
||||||
|
{
|
||||||
|
showLine = value;
|
||||||
|
line.Alpha = value ? 1 : 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
protected string Details
|
protected string Details
|
||||||
{
|
{
|
||||||
set => details.Text = value;
|
set => details.Text = value;
|
||||||
|
@ -94,45 +94,56 @@ namespace osu.Game.Screens.Multi.Match
|
|||||||
{
|
{
|
||||||
new Container
|
new Container
|
||||||
{
|
{
|
||||||
RelativeSizeAxes = Axes.Both,
|
RelativeSizeAxes = Axes.X,
|
||||||
Padding = new MarginPadding { Top = 65 },
|
AutoSizeAxes = Axes.Y,
|
||||||
Child = new GridContainer
|
Margin = new MarginPadding { Top = 10 },
|
||||||
|
Child = new OverlinedParticipants(Direction.Horizontal)
|
||||||
{
|
{
|
||||||
RelativeSizeAxes = Axes.Both,
|
RelativeSizeAxes = Axes.X,
|
||||||
Content = new[]
|
AutoSizeAxes = Axes.Y,
|
||||||
|
ShowLine = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
new Drawable[]
|
||||||
|
{
|
||||||
|
new GridContainer
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.Both,
|
||||||
|
Content = new[]
|
||||||
|
{
|
||||||
|
new Drawable[]
|
||||||
{
|
{
|
||||||
new Drawable[]
|
new Container
|
||||||
{
|
{
|
||||||
new Container
|
RelativeSizeAxes = Axes.Both,
|
||||||
|
Padding = new MarginPadding { Right = 5 },
|
||||||
|
Child = new OverlinedPlaylist(true) // Temporarily always allow selection
|
||||||
{
|
{
|
||||||
RelativeSizeAxes = Axes.Both,
|
RelativeSizeAxes = Axes.Both,
|
||||||
Padding = new MarginPadding { Right = 5 },
|
SelectedItem = { BindTarget = SelectedItem }
|
||||||
Child = new OverlinedPlaylist(true) // Temporarily always allow selection
|
|
||||||
{
|
|
||||||
RelativeSizeAxes = Axes.Both,
|
|
||||||
SelectedItem = { BindTarget = SelectedItem }
|
|
||||||
}
|
|
||||||
},
|
|
||||||
new Container
|
|
||||||
{
|
|
||||||
RelativeSizeAxes = Axes.Both,
|
|
||||||
Padding = new MarginPadding { Horizontal = 5 },
|
|
||||||
Child = leaderboard = new OverlinedLeaderboard { RelativeSizeAxes = Axes.Both },
|
|
||||||
},
|
|
||||||
new Container
|
|
||||||
{
|
|
||||||
RelativeSizeAxes = Axes.Both,
|
|
||||||
Padding = new MarginPadding { Left = 5 },
|
|
||||||
Child = new OverlinedChatDisplay { RelativeSizeAxes = Axes.Both }
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
}
|
new Container
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.Both,
|
||||||
|
Padding = new MarginPadding { Horizontal = 5 },
|
||||||
|
Child = leaderboard = new OverlinedLeaderboard { RelativeSizeAxes = Axes.Both },
|
||||||
|
},
|
||||||
|
new Container
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.Both,
|
||||||
|
Padding = new MarginPadding { Left = 5 },
|
||||||
|
Child = new OverlinedChatDisplay { RelativeSizeAxes = Axes.Both }
|
||||||
|
}
|
||||||
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
RowDimensions = new[]
|
RowDimensions = new[]
|
||||||
{
|
{
|
||||||
|
new Dimension(GridSizeMode.AutoSize),
|
||||||
new Dimension(GridSizeMode.AutoSize),
|
new Dimension(GridSizeMode.AutoSize),
|
||||||
new Dimension(),
|
new Dimension(),
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user