mirror of
https://github.com/ppy/osu.git
synced 2025-01-28 16:12:57 +08:00
Restructure Editor construction
This commit is contained in:
parent
7b1ef53f36
commit
221902f4fe
@ -26,24 +26,26 @@ namespace osu.Game.Screens.Edit
|
|||||||
|
|
||||||
public Editor()
|
public Editor()
|
||||||
{
|
{
|
||||||
Add(new Container
|
EditorMenuBar menuBar;
|
||||||
|
SummaryTimeline timeline;
|
||||||
|
|
||||||
|
Children = new[]
|
||||||
{
|
{
|
||||||
|
new Container
|
||||||
|
{
|
||||||
|
Name = "Top bar",
|
||||||
RelativeSizeAxes = Axes.X,
|
RelativeSizeAxes = Axes.X,
|
||||||
Height = 40,
|
Height = 40,
|
||||||
Children = new Drawable[]
|
Child = menuBar = new EditorMenuBar
|
||||||
{
|
|
||||||
new EditorMenuBar
|
|
||||||
{
|
{
|
||||||
Anchor = Anchor.CentreLeft,
|
Anchor = Anchor.CentreLeft,
|
||||||
Origin = Anchor.CentreLeft,
|
Origin = Anchor.CentreLeft,
|
||||||
RelativeSizeAxes = Axes.Both
|
RelativeSizeAxes = Axes.Both
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
});
|
new Container
|
||||||
|
|
||||||
SummaryTimeline summaryTimeline;
|
|
||||||
Add(new Container
|
|
||||||
{
|
{
|
||||||
|
Name = "Bottom bar",
|
||||||
Anchor = Anchor.BottomLeft,
|
Anchor = Anchor.BottomLeft,
|
||||||
Origin = Anchor.BottomLeft,
|
Origin = Anchor.BottomLeft,
|
||||||
RelativeSizeAxes = Axes.X,
|
RelativeSizeAxes = Axes.X,
|
||||||
@ -63,7 +65,7 @@ namespace osu.Game.Screens.Edit
|
|||||||
Spacing = new Vector2(10, 0),
|
Spacing = new Vector2(10, 0),
|
||||||
Children = new[]
|
Children = new[]
|
||||||
{
|
{
|
||||||
summaryTimeline = new SummaryTimeline
|
timeline = new SummaryTimeline
|
||||||
{
|
{
|
||||||
Anchor = Anchor.Centre,
|
Anchor = Anchor.Centre,
|
||||||
Origin = Anchor.Centre,
|
Origin = Anchor.Centre,
|
||||||
@ -74,9 +76,11 @@ namespace osu.Game.Screens.Edit
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
},
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
summaryTimeline.Beatmap.BindTo(Beatmap);
|
timeline.Beatmap.BindTo(Beatmap);
|
||||||
}
|
}
|
||||||
|
|
||||||
[BackgroundDependencyLoader]
|
[BackgroundDependencyLoader]
|
||||||
|
Loading…
Reference in New Issue
Block a user