osu/osu.Game.Tests/Visual/UserInterface/TestSceneVolumePieces.cs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

36 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-04-13 09:19:50 +00:00
2018-02-28 15:14:52 +00:00
using osu.Framework.Graphics;
using osu.Game.Overlays.Volume;
2018-11-20 07:51:59 +00:00
using osuTK;
using osuTK.Graphics;
2018-04-13 09:19:50 +00:00
2019-03-24 16:02:36 +00:00
namespace osu.Game.Tests.Visual.UserInterface
2018-02-28 15:14:52 +00:00
{
public partial class TestSceneVolumePieces : OsuTestScene
2018-02-28 15:14:52 +00:00
{
2018-03-03 19:20:07 +00:00
protected override void LoadComplete()
2018-02-28 15:14:52 +00:00
{
VolumeMeter meter;
2018-03-03 19:20:07 +00:00
MuteButton mute;
Add(meter = new VolumeMeter("MASTER", 125, Color4.Blue) { Position = new Vector2(10) });
AddSliderStep("master volume", 0, 10, 0, i => meter.Bindable.Value = i * 0.1);
Add(new VolumeMeter("BIG", 250, Color4.Red)
{
Anchor = Anchor.Centre,
Origin = Anchor.Centre,
Position = new Vector2(10),
});
2018-03-04 13:03:53 +00:00
Add(mute = new MuteButton
2018-02-28 15:14:52 +00:00
{
Margin = new MarginPadding { Top = 200 }
2018-03-04 13:03:53 +00:00
});
2018-04-13 09:19:50 +00:00
2018-03-03 19:20:07 +00:00
AddToggleStep("mute", b => mute.Current.Value = b);
2018-02-28 15:14:52 +00:00
}
}
}