1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-16 05:42:54 +08:00

Simplify MultiSpectatorScreen hierarchy construction

This commit is contained in:
Dean Herbert 2022-08-24 16:08:48 +09:00
parent 7c1fc4814e
commit 7f9246637a

View File

@ -73,15 +73,11 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer.Spectate
FillFlowContainer leaderboardFlow; FillFlowContainer leaderboardFlow;
Container scoreDisplayContainer; Container scoreDisplayContainer;
masterClockContainer = new MasterGameplayClockContainer(Beatmap.Value, 0); InternalChildren = new Drawable[]
InternalChildren = new[]
{ {
(Drawable)(syncManager = new SpectatorSyncManager(masterClockContainer) masterClockContainer = new MasterGameplayClockContainer(Beatmap.Value, 0)
{ {
ReadyToStart = performInitialSeek, Child = new GridContainer
}),
masterClockContainer.WithChild(new GridContainer
{ {
RelativeSizeAxes = Axes.Both, RelativeSizeAxes = Axes.Both,
RowDimensions = new[] { new Dimension(GridSizeMode.AutoSize) }, RowDimensions = new[] { new Dimension(GridSizeMode.AutoSize) },
@ -119,7 +115,12 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer.Spectate
} }
} }
} }
}) }
},
syncManager = new SpectatorSyncManager(masterClockContainer)
{
ReadyToStart = performInitialSeek,
}
}; };
for (int i = 0; i < Users.Count; i++) for (int i = 0; i < Users.Count; i++)