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/SelectionBlueprintTestScene.cs

37 lines
1.1 KiB
C#
Raw Normal View History

// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
2018-10-25 17:48:11 +08:00
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Timing;
using osu.Game.Rulesets.Edit;
using osu.Game.Rulesets.Objects.Drawables;
2018-10-25 17:48:11 +08:00
namespace osu.Game.Tests.Visual
{
public abstract class SelectionBlueprintTestScene : OsuManualInputManagerTestScene
2018-10-25 17:48:11 +08:00
{
protected override Container<Drawable> Content => content ?? base.Content;
private readonly Container content;
protected SelectionBlueprintTestScene()
2018-10-25 17:48:11 +08:00
{
base.Content.Add(content = new Container
{
Clock = new FramedClock(new StopwatchClock()),
RelativeSizeAxes = Axes.Both
});
}
protected void AddBlueprint(HitObjectSelectionBlueprint blueprint, DrawableHitObject drawableObject)
2018-10-25 17:48:11 +08:00
{
Add(blueprint.With(d =>
{
2021-05-18 13:26:26 +08:00
d.DrawableObject = drawableObject;
d.Depth = float.MinValue;
d.Select();
}));
2018-10-25 17:48:11 +08:00
}
}
}