1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-14 10:57:30 +08:00
osu-lazer/osu.Game.Tests/Visual/TestCaseEditorComposeTimeline.cs

50 lines
1.6 KiB
C#
Raw Normal View History

2018-01-05 19:21:19 +08:00
// Copyright (c) 2007-2018 ppy Pty Ltd <contact@ppy.sh>.
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
using System;
using System.Collections.Generic;
2018-03-02 14:34:31 +08:00
using NUnit.Framework;
using OpenTK;
using osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Game.Overlays;
2017-10-10 14:22:32 +08:00
using osu.Game.Screens.Edit.Screens.Compose.Timeline;
namespace osu.Game.Tests.Visual
{
2018-03-02 14:34:31 +08:00
[TestFixture]
public class TestCaseEditorComposeTimeline : OsuTestCase
{
2018-04-05 18:40:03 +08:00
public override IReadOnlyList<Type> RequiredTypes => new[] { typeof(TimelineArea), typeof(Timeline), typeof(BeatmapWaveformGraph), typeof(TimelineButton) };
2018-04-05 18:40:03 +08:00
private readonly TimelineArea timelineArea;
public TestCaseEditorComposeTimeline()
{
Children = new Drawable[]
{
new MusicController
{
Anchor = Anchor.TopCentre,
Origin = Anchor.TopCentre,
State = Visibility.Visible
},
2018-04-05 18:40:03 +08:00
timelineArea = new TimelineArea
{
Anchor = Anchor.Centre,
Origin = Anchor.Centre,
RelativeSizeAxes = Axes.X,
Size = new Vector2(0.8f, 100)
}
};
}
[BackgroundDependencyLoader]
private void load(OsuGameBase osuGame)
{
2018-04-05 18:40:03 +08:00
timelineArea.Beatmap.BindTo(osuGame.Beatmap);
}
}
}