aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorxander <xander@isxander.dev>2022-09-20 18:50:42 +0100
committerxander <xander@isxander.dev>2022-09-20 18:50:42 +0100
commit22fa08459b8c5e99e1e309ae42a146026246c422 (patch)
tree670d106c499db6f67195d2ab9202b0afd9137d08
parent110b0bdf9d6720e09c1dc97c0b6192e933200a94 (diff)
downloadYetAnotherConfigLib-22fa08459b8c5e99e1e309ae42a146026246c422.tar.gz
YetAnotherConfigLib-22fa08459b8c5e99e1e309ae42a146026246c422.tar.bz2
YetAnotherConfigLib-22fa08459b8c5e99e1e309ae42a146026246c422.zip
Fix slider tooltip showing when not hovering
-rw-r--r--build.gradle.kts2
-rw-r--r--changelogs/1.4.1.md1
-rw-r--r--src/main/java/dev/isxander/yacl/gui/controllers/slider/SliderControllerElement.java6
3 files changed, 8 insertions, 1 deletions
diff --git a/build.gradle.kts b/build.gradle.kts
index 20b921e..2bab14b 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -16,7 +16,7 @@ plugins {
val ciRun = System.getenv().containsKey("GITHUB_ACTIONS")
group = "dev.isxander"
-version = "1.4.0"
+version = "1.4.1"
if (ciRun)
version = "$version-SNAPSHOT"
diff --git a/changelogs/1.4.1.md b/changelogs/1.4.1.md
new file mode 100644
index 0000000..bfcd366
--- /dev/null
+++ b/changelogs/1.4.1.md
@@ -0,0 +1 @@
+- Fix slider tooltip showing when not hovering
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 d07377a..01ac336 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
@@ -150,4 +150,10 @@ public class SliderControllerElement extends ControllerWidget<ISliderController<
private int getThumbWidth() {
return 4;
}
+
+ @Override
+ public void postRender(MatrixStack matrices, int mouseX, int mouseY, float delta) {
+ if (super.isMouseOver(mouseX, mouseY))
+ super.postRender(matrices, mouseX, mouseY, delta);
+ }
}