control preset to be stored into separate file

This commit is contained in:
minjaesong
2026-02-07 16:19:42 +09:00
parent e838991826
commit 068d0bf1b2
22 changed files with 336 additions and 87 deletions

View File

@@ -87,7 +87,7 @@ class ConsoleWindow : UICanvas() {
releaseTooltip()
// click to enter the actor's reference ID
if (lb.size > 0 && !clickLatched && Gdx.input.isButtonPressed(App.getConfigInt("config_mouseprimary"))) {
if (lb.size > 0 && !clickLatched && Gdx.input.isButtonPressed(App.getConfigInt("control_mouse_primary"))) {
clickLatched = true
textinput.appendText(lb.first().substringBefore(' '))
}
@@ -100,7 +100,7 @@ class ConsoleWindow : UICanvas() {
uiItems.forEach { it.update(delta) }
if (!Gdx.input.isButtonPressed(App.getConfigInt("config_mouseprimary"))) {
if (!Gdx.input.isButtonPressed(App.getConfigInt("control_mouse_primary"))) {
clickLatched = false
}

View File

@@ -7,7 +7,7 @@ import java.util.concurrent.atomic.AtomicBoolean
/**
* Created by minjaesong on 2024-01-10.
*/
class MouseLatch(val button: List<Int> = listOf(App.getConfigInt("config_mouseprimary"))) {
class MouseLatch(val button: List<Int> = listOf(App.getConfigInt("control_mouse_primary"))) {
private val status = AtomicBoolean()

View File

@@ -249,7 +249,7 @@ abstract class UIItem(var parentUI: UICanvas, val initialX: Int, val initialY: I
actionDone = true
}
if (!clickOnceListenerFired && mouseUp && button == App.getConfigInt("config_mouseprimary")) {
if (!clickOnceListenerFired && mouseUp && button == App.getConfigInt("control_mouse_primary")) {
clickOnceListener.invoke(itemRelativeMouseX, itemRelativeMouseY)
if (!suppressHaptic)
playHapticPushedDown()