1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-12 04:49:40 +08:00
osu-lazer/osu.Desktop.VisualTests/Tests/TestCaseModSelectOverlay.cs

36 lines
1.2 KiB
C#
Raw Normal View History

2017-02-17 04:05:03 +08:00
// Copyright (c) 2007-2017 ppy Pty Ltd <contact@ppy.sh>.
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
using osu.Framework.Graphics;
using osu.Game.Overlays.Mods;
2017-02-23 00:46:38 +08:00
using osu.Framework.Screens.Testing;
2017-02-17 04:05:03 +08:00
using osu.Game.Modes;
namespace osu.Desktop.VisualTests.Tests
{
class TestCaseModSelectOverlay : TestCase
2017-02-17 04:05:03 +08:00
{
public override string Description => @"Tests the mod select overlay";
2017-02-17 04:05:03 +08:00
private ModSelectOverlay modSelect;
2017-02-17 04:05:03 +08:00
public override void Reset()
{
base.Reset();
Add(modSelect = new ModSelectOverlay
2017-02-17 04:05:03 +08:00
{
RelativeSizeAxes = Axes.X,
2017-02-17 04:05:03 +08:00
Origin = Anchor.BottomCentre,
Anchor = Anchor.BottomCentre,
});
AddButton("Toggle", modSelect.ToggleVisibility);
2017-03-02 20:14:06 +08:00
AddButton("osu!", () => modSelect.PlayMode.Value = PlayMode.Osu);
AddButton("osu!taiko", () => modSelect.PlayMode.Value = PlayMode.Taiko);
AddButton("osu!catch", () => modSelect.PlayMode.Value = PlayMode.Catch);
AddButton("osu!mania", () => modSelect.PlayMode.Value = PlayMode.Mania);
2017-02-17 04:05:03 +08:00
}
}
}