2017-02-07 13:59:30 +09:00
|
|
|
|
// Copyright (c) 2007-2017 ppy Pty Ltd <contact@ppy.sh>.
|
|
|
|
|
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
2016-12-14 14:59:23 -05:00
|
|
|
|
|
2017-05-16 21:49:38 +08:00
|
|
|
|
using System;
|
2016-11-30 09:08:11 -05:00
|
|
|
|
using osu.Framework.Graphics;
|
2017-04-21 13:59:04 +02:00
|
|
|
|
using osu.Framework.Graphics.UserInterface;
|
2017-02-04 09:50:58 +01:00
|
|
|
|
using osu.Game.Graphics.UserInterface;
|
2016-11-30 09:08:11 -05:00
|
|
|
|
|
2017-05-15 10:55:29 +09:00
|
|
|
|
namespace osu.Game.Overlays.Settings
|
2016-12-07 15:39:21 -05:00
|
|
|
|
{
|
2017-05-15 10:55:29 +09:00
|
|
|
|
public class SettingsSlider<T> : SettingsSlider<T, OsuSliderBar<T>>
|
2017-05-16 21:49:38 +08:00
|
|
|
|
where T : struct, IEquatable<T>
|
2016-12-07 15:39:21 -05:00
|
|
|
|
{
|
2017-04-21 13:59:04 +02:00
|
|
|
|
}
|
|
|
|
|
|
2017-05-15 10:55:29 +09:00
|
|
|
|
public class SettingsSlider<T, U> : SettingsItem<T>
|
2017-05-16 21:49:38 +08:00
|
|
|
|
where T : struct, IEquatable<T>
|
2017-05-02 18:53:33 +09:00
|
|
|
|
where U : SliderBar<T>, new()
|
2017-04-21 13:59:04 +02:00
|
|
|
|
{
|
2017-07-13 15:02:45 +09:00
|
|
|
|
protected override Drawable CreateControl() => new U
|
2016-12-07 15:39:21 -05:00
|
|
|
|
{
|
2017-05-04 23:07:24 +09:00
|
|
|
|
Margin = new MarginPadding { Top = 5, Bottom = 5 },
|
|
|
|
|
RelativeSizeAxes = Axes.X
|
|
|
|
|
};
|
2016-12-07 15:39:21 -05:00
|
|
|
|
}
|
2016-12-09 08:18:58 -05:00
|
|
|
|
}
|