1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-15 09:02:55 +08:00

Merge pull request from Joehuu/drawable-room-ffc-instead-of-gc

Use `Anchor`/`Origin` instead of `GridContainer` for drawable room background gradient
This commit is contained in:
Dean Herbert 2023-06-13 17:49:57 +09:00 committed by GitHub
commit 411979be81
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -102,30 +102,20 @@ namespace osu.Game.Screens.OnlinePlay.Lounge.Components
Masking = true, Masking = true,
CornerRadius = CORNER_RADIUS, CornerRadius = CORNER_RADIUS,
Children = new Drawable[] Children = new Drawable[]
{
new GridContainer
{
RelativeSizeAxes = Axes.Both,
ColumnDimensions = new[]
{
new Dimension(GridSizeMode.Relative, 0.2f)
},
Content = new[]
{
new Drawable[]
{ {
new Box new Box
{ {
RelativeSizeAxes = Axes.Both, RelativeSizeAxes = Axes.Both,
Colour = colours.Background5, Colour = colours.Background5,
Width = 0.2f,
}, },
new Box new Box
{ {
Anchor = Anchor.TopRight,
Origin = Anchor.TopRight,
RelativeSizeAxes = Axes.Both, RelativeSizeAxes = Axes.Both,
Colour = ColourInfo.GradientHorizontal(colours.Background5, colours.Background5.Opacity(0.3f)) Colour = ColourInfo.GradientHorizontal(colours.Background5, colours.Background5.Opacity(0.3f)),
}, Width = 0.8f,
}
}
}, },
new Container new Container
{ {