Pass adjustable clocks to components, rather than relying on the track

This commit is contained in:
smoogipoo
2018-03-15 18:08:37 +09:00
parent c8f6a6980b
commit d05947ef48
6 changed files with 33 additions and 24 deletions

View File

@ -6,6 +6,7 @@ using osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Shapes;
using osu.Framework.Timing;
using osu.Game.Graphics;
using osu.Game.Screens.Edit.Components.Timelines.Summary.Parts;
@ -18,13 +19,13 @@ namespace osu.Game.Screens.Edit.Components.Timelines.Summary
{
private readonly Drawable timelineBar;
public SummaryTimeline()
public SummaryTimeline(IAdjustableClock adjustableClock)
{
TimelinePart markerPart, controlPointPart, bookmarkPart, breakPart;
Children = new[]
{
markerPart = new MarkerPart { RelativeSizeAxes = Axes.Both },
markerPart = new MarkerPart(adjustableClock) { RelativeSizeAxes = Axes.Both },
controlPointPart = new ControlPointPart
{
Anchor = Anchor.Centre,