1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-12 05:27:40 +08:00

Line length is calculated inline

This commit is contained in:
Jorolf 2017-02-14 16:05:57 +01:00
parent 1b08f6aca4
commit e717daa504

View File

@ -31,9 +31,6 @@ namespace osu.Game.Overlays.Toolbar
{ {
RelativeSizeAxes = Axes.Y; RelativeSizeAxes = Axes.Y;
float lineLength = padding * 2 + ToolbarButton.WIDTH;
Children = new Drawable[] Children = new Drawable[]
{ {
new OpaqueBackground(), new OpaqueBackground(),
@ -48,7 +45,7 @@ namespace osu.Game.Overlays.Toolbar
}, },
modeButtonLine = new Container modeButtonLine = new Container
{ {
Size = new Vector2(lineLength, 3), Size = new Vector2(padding * 2 + ToolbarButton.WIDTH, 3),
Anchor = Anchor.BottomLeft, Anchor = Anchor.BottomLeft,
Origin = Anchor.TopLeft, Origin = Anchor.TopLeft,
Masking = true, Masking = true,