aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/cc/polyfrost/oneconfig/gui/pages/ModsPage.java
diff options
context:
space:
mode:
authorDeDiamondPro <67508414+DeDiamondPro@users.noreply.github.com>2022-06-04 13:36:46 +0200
committerDeDiamondPro <67508414+DeDiamondPro@users.noreply.github.com>2022-06-04 13:36:46 +0200
commita4d135ebb02c6fea87c8f9275a8a07338999d84b (patch)
treea8bafe2e44307255e9c9eef14a9baf6d26e37c73 /src/main/java/cc/polyfrost/oneconfig/gui/pages/ModsPage.java
parent07741d92fa6ea636b8292bb35706c25e5e6a72cc (diff)
downloadOneConfig-a4d135ebb02c6fea87c8f9275a8a07338999d84b.tar.gz
OneConfig-a4d135ebb02c6fea87c8f9275a8a07338999d84b.tar.bz2
OneConfig-a4d135ebb02c6fea87c8f9275a8a07338999d84b.zip
OC-66 done
Diffstat (limited to 'src/main/java/cc/polyfrost/oneconfig/gui/pages/ModsPage.java')
-rw-r--r--src/main/java/cc/polyfrost/oneconfig/gui/pages/ModsPage.java10
1 files changed, 4 insertions, 6 deletions
diff --git a/src/main/java/cc/polyfrost/oneconfig/gui/pages/ModsPage.java b/src/main/java/cc/polyfrost/oneconfig/gui/pages/ModsPage.java
index 6df01e1..2866008 100644
--- a/src/main/java/cc/polyfrost/oneconfig/gui/pages/ModsPage.java
+++ b/src/main/java/cc/polyfrost/oneconfig/gui/pages/ModsPage.java
@@ -32,14 +32,12 @@ public class ModsPage extends Page {
modCategories.add(new BasicButton(80, 32, "Hypixel", BasicButton.ALIGNMENT_CENTER, ColorPalette.SECONDARY));
modCategories.add(new BasicButton(80, 32, "Skyblock", BasicButton.ALIGNMENT_CENTER, ColorPalette.SECONDARY));
modCategories.add(new BasicButton(88, 32, "3rd Party", BasicButton.ALIGNMENT_CENTER, ColorPalette.SECONDARY));
- modCategories.get(0).setToggled(true);
- int i = 0;
- for (BasicButton button : modCategories) {
- button.setToggleable(true);
+ for (int i = 0; i < modCategories.size(); i++) {
+ modCategories.get(i).setToggleable(true);
int finalI = i;
- button.setClickAction(() -> unselect(finalI));
- i++;
+ modCategories.get(i).setClickAction(() -> unselect(finalI));
}
+ modCategories.get(0).setToggled(true);
}
public void draw(long vg, int x, int y) {