1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-13 05:22:54 +08:00

Fix right mouse scroll clamping not going along well with padding

Co-authored-by: Joseph Madamba <madamba.joehu@outlook.com>
This commit is contained in:
Bartłomiej Dach 2024-02-28 15:59:22 +01:00
parent cc341b4119
commit c10ba6ece9
No known key found for this signature in database

View File

@ -127,7 +127,7 @@ namespace osu.Game.Graphics.Containers
}
protected virtual void ScrollFromMouseEvent(MouseEvent e) =>
ScrollTo(Clamp(ToLocalSpace(e.ScreenSpaceMousePosition)[ScrollDim] / DrawSize[ScrollDim]) * Content.DrawSize[ScrollDim], true, DistanceDecayOnRightMouseScrollbar);
ScrollTo(Clamp(ToLocalSpace(e.ScreenSpaceMousePosition)[ScrollDim] / DrawSize[ScrollDim] * Content.DrawSize[ScrollDim]), true, DistanceDecayOnRightMouseScrollbar);
protected override ScrollbarContainer CreateScrollbar(Direction direction) => new OsuScrollbar(direction);