aboutsummaryrefslogtreecommitdiff
path: root/src/main/kotlin/cc/polyfrost/oneconfig
diff options
context:
space:
mode:
authorDeDiamondPro <67508414+DeDiamondPro@users.noreply.github.com>2022-08-17 17:43:23 +0200
committerGitHub <noreply@github.com>2022-08-17 17:43:23 +0200
commit97f788ecd4be15b1556ee1f3d8bd057bdf06bf5f (patch)
tree2bccc96007025fbccf1758ac66d4665a97d6c315 /src/main/kotlin/cc/polyfrost/oneconfig
parente18629af6aee276b0be6cec473e4099cca9100f1 (diff)
downloadOneConfig-97f788ecd4be15b1556ee1f3d8bd057bdf06bf5f.tar.gz
OneConfig-97f788ecd4be15b1556ee1f3d8bd057bdf06bf5f.tar.bz2
OneConfig-97f788ecd4be15b1556ee1f3d8bd057bdf06bf5f.zip
Input revamp (#93)
* hud fix * api * things * stuff
Diffstat (limited to 'src/main/kotlin/cc/polyfrost/oneconfig')
-rw-r--r--src/main/kotlin/cc/polyfrost/oneconfig/utils/dsl/RenderManagerDSL.kt8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/main/kotlin/cc/polyfrost/oneconfig/utils/dsl/RenderManagerDSL.kt b/src/main/kotlin/cc/polyfrost/oneconfig/utils/dsl/RenderManagerDSL.kt
index 1dd3499..ac6ff9c 100644
--- a/src/main/kotlin/cc/polyfrost/oneconfig/utils/dsl/RenderManagerDSL.kt
+++ b/src/main/kotlin/cc/polyfrost/oneconfig/utils/dsl/RenderManagerDSL.kt
@@ -31,6 +31,7 @@ import cc.polyfrost.oneconfig.renderer.RenderManager
import cc.polyfrost.oneconfig.renderer.font.Font
import cc.polyfrost.oneconfig.renderer.Image
import cc.polyfrost.oneconfig.renderer.SVG
+import cc.polyfrost.oneconfig.utils.InputHandler
import cc.polyfrost.oneconfig.utils.color.ColorUtils
import org.lwjgl.nanovg.NVGColor
@@ -169,10 +170,11 @@ fun Long.drawWrappedString(text: String, x: Number, y: Number, width: Number, co
fun VG.drawWrappedString(text: String, x: Number, y: Number, width: Number, color: Int, size: Number, font: Font) =
instance.drawWrappedString(text, x, y, width, color, size, font)
-fun Long.drawURL(url: String, x: Number, y: Number, size: Number, font: Font) =
- RenderManager.drawURL(this, url, x.toFloat(), y.toFloat(), size.toFloat(), font)
+fun Long.drawURL(url: String, x: Number, y: Number, size: Number, font: Font, inputHandler: InputHandler) =
+ RenderManager.drawURL(this, url, x.toFloat(), y.toFloat(), size.toFloat(), font, inputHandler)
-fun VG.drawURL(url: String, x: Number, y: Number, size: Number, font: Font) = instance.drawURL(url, x, y, size, font)
+fun VG.drawURL(url: String, x: Number, y: Number, size: Number, font: Font, inputHandler: InputHandler) =
+ instance.drawURL(url, x, y, size, font, inputHandler)
fun Long.drawImage(filePath: String, x: Number, y: Number, width: Number, height: Number) =