mirror of
https://github.com/ppy/osu.git
synced 2024-11-06 06:17:23 +08:00
Drop SliderBarEventSource
This commit is contained in:
parent
abc6db18b3
commit
80574423cb
@ -145,19 +145,16 @@ namespace osu.Game.Overlays.Options
|
||||
|
||||
protected override void Update()
|
||||
{
|
||||
base.Update();
|
||||
leftBox.Scale = new Vector2(MathHelper.Clamp(
|
||||
nub.DrawPosition.X - nub.DrawSize.X / 2 + 2, 0, DrawWidth), 1);
|
||||
rightBox.Scale = new Vector2(MathHelper.Clamp(
|
||||
DrawWidth - nub.DrawPosition.X - nub.DrawSize.X / 2 + 2, 0, DrawWidth), 1);
|
||||
base.Update();
|
||||
}
|
||||
|
||||
protected override void UpdateValue(float value, SliderBarEventSource eventSource)
|
||||
protected override void UpdateValue(float value)
|
||||
{
|
||||
if (eventSource == SliderBarEventSource.Keyboard)
|
||||
nub.MoveToX(DrawWidth * value, 300, EasingTypes.OutQuint);
|
||||
else
|
||||
nub.Position = new Vector2(DrawWidth * value, nub.Position.Y);
|
||||
nub.Position = new Vector2(DrawWidth * value, nub.Position.Y);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user