From 7c58fdd5aa54e88c1526c49adacaf97cf3810eba Mon Sep 17 00:00:00 2001 From: xander Date: Fri, 2 Sep 2022 11:10:42 +0100 Subject: allow slider dragging to continue outside of bounds increase thumb-height by 2px --- .../yacl/gui/controllers/slider/SliderControllerElement.java | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'src/main') diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/slider/SliderControllerElement.java b/src/main/java/dev/isxander/yacl/gui/controllers/slider/SliderControllerElement.java index 104140d..997ba7d 100644 --- a/src/main/java/dev/isxander/yacl/gui/controllers/slider/SliderControllerElement.java +++ b/src/main/java/dev/isxander/yacl/gui/controllers/slider/SliderControllerElement.java @@ -67,7 +67,7 @@ public class SliderControllerElement extends ControllerWidget dim) { super.setDimension(dim); - sliderBounds = Dimension.ofInt(dim.xLimit() - getXPadding() - getThumbWidth() / 2 - dim.width() / 3, dim.centerY() - 4, dim.width() / 3, 8); + sliderBounds = Dimension.ofInt(dim.xLimit() - getXPadding() - getThumbWidth() / 2 - dim.width() / 3, dim.centerY() - 5, dim.width() / 3, 10); } private int getThumbX() { -- cgit