2016-11-09 03:38:40 +00:00
|
|
|
|
using osu.Framework;
|
|
|
|
|
using osu.Framework.Graphics;
|
2016-11-03 04:26:49 +00:00
|
|
|
|
using osu.Framework.Graphics.Sprites;
|
|
|
|
|
using osu.Framework.Graphics.UserInterface;
|
2016-11-09 03:38:40 +00:00
|
|
|
|
using osu.Game.Configuration;
|
2016-11-03 04:26:49 +00:00
|
|
|
|
|
2016-11-08 02:24:41 +00:00
|
|
|
|
namespace osu.Game.Overlays.Options.Input
|
2016-11-03 04:26:49 +00:00
|
|
|
|
{
|
|
|
|
|
public class MouseOptions : OptionsSubsection
|
|
|
|
|
{
|
2016-11-09 03:38:40 +00:00
|
|
|
|
protected override string Header => "Mouse";
|
|
|
|
|
|
|
|
|
|
private CheckBoxOption rawInput, mapRawInput, disableWheel, disableButtons, enableRipples;
|
|
|
|
|
|
2016-11-03 04:26:49 +00:00
|
|
|
|
public MouseOptions()
|
|
|
|
|
{
|
|
|
|
|
Children = new Drawable[]
|
|
|
|
|
{
|
|
|
|
|
new SpriteText { Text = "Sensitivity: TODO slider" },
|
2016-11-09 03:38:40 +00:00
|
|
|
|
rawInput = new CheckBoxOption { LabelText = "Raw input" },
|
|
|
|
|
mapRawInput = new CheckBoxOption { LabelText = "Map absolute raw input to the osu! window" },
|
2016-11-03 04:26:49 +00:00
|
|
|
|
new SpriteText { Text = "Confine mouse cursor: TODO dropdown" },
|
2016-11-09 03:38:40 +00:00
|
|
|
|
disableWheel = new CheckBoxOption { LabelText = "Disable mouse wheel in play mode" },
|
|
|
|
|
disableButtons = new CheckBoxOption { LabelText = "Disable mouse buttons in play mode" },
|
|
|
|
|
enableRipples = new CheckBoxOption { LabelText = "Cursor ripples" },
|
2016-11-03 04:26:49 +00:00
|
|
|
|
};
|
2016-11-09 03:38:40 +00:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected override void Load(BaseGame game)
|
|
|
|
|
{
|
|
|
|
|
base.Load(game);
|
|
|
|
|
var osuGame = game as OsuGameBase;
|
|
|
|
|
if (osuGame != null)
|
|
|
|
|
{
|
|
|
|
|
rawInput.Bindable = osuGame.Config.GetBindable<bool>(OsuConfig.RawInput);
|
|
|
|
|
mapRawInput.Bindable = osuGame.Config.GetBindable<bool>(OsuConfig.AbsoluteToOsuWindow);
|
|
|
|
|
disableWheel.Bindable = osuGame.Config.GetBindable<bool>(OsuConfig.MouseDisableWheel);
|
|
|
|
|
disableButtons.Bindable = osuGame.Config.GetBindable<bool>(OsuConfig.MouseDisableButtons);
|
|
|
|
|
enableRipples.Bindable = osuGame.Config.GetBindable<bool>(OsuConfig.CursorRipple);
|
|
|
|
|
}
|
2016-11-03 04:26:49 +00:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|