aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/kr/syeyoung/dungeonsguide/gui
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/kr/syeyoung/dungeonsguide/gui')
-rwxr-xr-xsrc/main/java/kr/syeyoung/dungeonsguide/gui/elements/MStringSelectionButton.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/main/java/kr/syeyoung/dungeonsguide/gui/elements/MStringSelectionButton.java b/src/main/java/kr/syeyoung/dungeonsguide/gui/elements/MStringSelectionButton.java
index 7666865a..f2dcadce 100755
--- a/src/main/java/kr/syeyoung/dungeonsguide/gui/elements/MStringSelectionButton.java
+++ b/src/main/java/kr/syeyoung/dungeonsguide/gui/elements/MStringSelectionButton.java
@@ -54,8 +54,8 @@ public class MStringSelectionButton extends MPanel {
dec.setOnActionPerformed(new Runnable() {
@Override
public void run() {
- selectedIndex++;
- if (selectedIndex >= possible.size()) selectedIndex = 0;
+ selectedIndex --;
+ if (selectedIndex < 0) selectedIndex = possible.size() - 1;
updateSelected();
onUpdate.run();
}
@@ -63,8 +63,8 @@ public class MStringSelectionButton extends MPanel {
inc.setOnActionPerformed(new Runnable() {
@Override
public void run() {
- selectedIndex --;
- if (selectedIndex < 0) selectedIndex = possible.size() - 1;
+ selectedIndex++;
+ if (selectedIndex >= possible.size()) selectedIndex = 0;
updateSelected();
onUpdate.run();
}