Re-layout to reduce movement

This commit is contained in:
smoogipoo 2021-02-03 14:52:36 +09:00
parent 2a4488c11b
commit 21d5f842fc

View File

@ -97,18 +97,19 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer
}, },
new Drawable[] new Drawable[]
{ {
new GridContainer new Container
{
RelativeSizeAxes = Axes.Both,
Padding = new MarginPadding { Horizontal = 5, Vertical = 10 },
Child = new GridContainer
{ {
RelativeSizeAxes = Axes.Both, RelativeSizeAxes = Axes.Both,
Content = new[] Content = new[]
{ {
new Drawable[] new Drawable[]
{ {
new Container // Main left column
{ new GridContainer
RelativeSizeAxes = Axes.Both,
Padding = new MarginPadding { Horizontal = 5, Vertical = 10 },
Child = new GridContainer
{ {
RelativeSizeAxes = Axes.Both, RelativeSizeAxes = Axes.Both,
RowDimensions = new[] RowDimensions = new[]
@ -126,16 +127,12 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer
}, },
} }
} }
}
}, },
// Main right column
new FillFlowContainer new FillFlowContainer
{ {
Anchor = Anchor.Centre,
Origin = Anchor.Centre,
RelativeSizeAxes = Axes.X, RelativeSizeAxes = Axes.X,
AutoSizeAxes = Axes.Y, AutoSizeAxes = Axes.Y,
Padding = new MarginPadding { Horizontal = 5 },
Spacing = new Vector2(0, 10),
Children = new[] Children = new[]
{ {
new FillFlowContainer new FillFlowContainer
@ -152,19 +149,35 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer
{ {
RelativeSizeAxes = Axes.X, RelativeSizeAxes = Axes.X,
AutoSizeAxes = Axes.Y, AutoSizeAxes = Axes.Y,
Margin = new MarginPadding { Top = 10 },
Children = new Drawable[] Children = new Drawable[]
{ {
new OverlinedHeader("Extra mods"), new OverlinedHeader("Extra mods"),
new ModDisplay new FillFlowContainer
{
AutoSizeAxes = Axes.Both,
Direction = FillDirection.Horizontal,
Spacing = new Vector2(10, 0),
Children = new Drawable[]
{ {
DisplayUnrankedText = false,
Current = UserMods
},
new PurpleTriangleButton new PurpleTriangleButton
{ {
RelativeSizeAxes = Axes.X, Anchor = Anchor.CentreLeft,
Origin = Anchor.CentreLeft,
Width = 90,
Text = "Select", Text = "Select",
Action = () => userModsSelectOverlay.Show() Action = () => userModsSelectOverlay.Show()
},
new ModDisplay
{
Anchor = Anchor.CentreLeft,
Origin = Anchor.CentreLeft,
DisplayUnrankedText = false,
Current = UserMods,
Scale = new Vector2(0.8f),
},
}
}
} }
} }
} }