aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorisXander <xandersmith2008@gmail.com>2022-11-27 18:17:36 +0000
committerisXander <xandersmith2008@gmail.com>2022-11-27 18:17:36 +0000
commitd163b9128d760e53e34fd6c08dbf782fa3d50c51 (patch)
treeb9ea79bb99bf52ea7de9d059cc05900270ff88d4 /src
parentc26d3a89caae20f1a91898202d91de8dc90da5ad (diff)
downloadYetAnotherConfigLib-d163b9128d760e53e34fd6c08dbf782fa3d50c51.tar.gz
YetAnotherConfigLib-d163b9128d760e53e34fd6c08dbf782fa3d50c51.tar.bz2
YetAnotherConfigLib-d163b9128d760e53e34fd6c08dbf782fa3d50c51.zip
split sourcesets
Diffstat (limited to 'src')
-rw-r--r--src/client/java/dev/isxander/yacl/api/Binding.java (renamed from src/main/java/dev/isxander/yacl/api/Binding.java)2
-rw-r--r--src/client/java/dev/isxander/yacl/api/ButtonOption.java (renamed from src/main/java/dev/isxander/yacl/api/ButtonOption.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/api/ConfigCategory.java (renamed from src/main/java/dev/isxander/yacl/api/ConfigCategory.java)1
-rw-r--r--src/client/java/dev/isxander/yacl/api/Controller.java (renamed from src/main/java/dev/isxander/yacl/api/Controller.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/api/NameableEnum.java (renamed from src/main/java/dev/isxander/yacl/api/NameableEnum.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/api/Option.java (renamed from src/main/java/dev/isxander/yacl/api/Option.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/api/OptionFlag.java (renamed from src/main/java/dev/isxander/yacl/api/OptionFlag.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/api/OptionGroup.java (renamed from src/main/java/dev/isxander/yacl/api/OptionGroup.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/api/PlaceholderCategory.java (renamed from src/main/java/dev/isxander/yacl/api/PlaceholderCategory.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/api/YetAnotherConfigLib.java (renamed from src/main/java/dev/isxander/yacl/api/YetAnotherConfigLib.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/api/utils/Dimension.java (renamed from src/main/java/dev/isxander/yacl/api/utils/Dimension.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/api/utils/MutableDimension.java (renamed from src/main/java/dev/isxander/yacl/api/utils/MutableDimension.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/api/utils/OptionUtils.java (renamed from src/main/java/dev/isxander/yacl/api/utils/OptionUtils.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/AbstractWidget.java (renamed from src/main/java/dev/isxander/yacl/gui/AbstractWidget.java)2
-rw-r--r--src/client/java/dev/isxander/yacl/gui/CategoryListWidget.java (renamed from src/main/java/dev/isxander/yacl/gui/CategoryListWidget.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/CategoryWidget.java (renamed from src/main/java/dev/isxander/yacl/gui/CategoryWidget.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/LowProfileButtonWidget.java (renamed from src/main/java/dev/isxander/yacl/gui/LowProfileButtonWidget.java)2
-rw-r--r--src/client/java/dev/isxander/yacl/gui/OptionListWidget.java (renamed from src/main/java/dev/isxander/yacl/gui/OptionListWidget.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/RequireRestartScreen.java (renamed from src/main/java/dev/isxander/yacl/gui/RequireRestartScreen.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/SearchFieldWidget.java (renamed from src/main/java/dev/isxander/yacl/gui/SearchFieldWidget.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/TextScaledButtonWidget.java (renamed from src/main/java/dev/isxander/yacl/gui/TextScaledButtonWidget.java)2
-rw-r--r--src/client/java/dev/isxander/yacl/gui/TooltipButtonWidget.java (renamed from src/main/java/dev/isxander/yacl/gui/TooltipButtonWidget.java)2
-rw-r--r--src/client/java/dev/isxander/yacl/gui/YACLScreen.java (renamed from src/main/java/dev/isxander/yacl/gui/YACLScreen.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/ActionController.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/ActionController.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/BooleanController.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/BooleanController.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/ColorController.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/ColorController.java)2
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/ControllerWidget.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/ControllerWidget.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/LabelController.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/LabelController.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/TickBoxController.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/TickBoxController.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/cycling/CyclingControllerElement.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/cycling/CyclingControllerElement.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/cycling/CyclingListController.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/cycling/CyclingListController.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/cycling/EnumController.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/cycling/EnumController.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/cycling/ICyclingController.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/cycling/ICyclingController.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/package-info.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/package-info.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/slider/DoubleSliderController.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/slider/DoubleSliderController.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/slider/FloatSliderController.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/slider/FloatSliderController.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/slider/ISliderController.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/slider/ISliderController.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/slider/IntegerSliderController.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/slider/IntegerSliderController.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/slider/LongSliderController.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/slider/LongSliderController.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/slider/SliderControllerElement.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/slider/SliderControllerElement.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/slider/package-info.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/slider/package-info.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/string/IStringController.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/string/IStringController.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/string/StringController.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/string/StringController.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/gui/controllers/string/StringControllerElement.java (renamed from src/main/java/dev/isxander/yacl/gui/controllers/string/StringControllerElement.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/impl/ButtonOptionImpl.java (renamed from src/main/java/dev/isxander/yacl/impl/ButtonOptionImpl.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/impl/ConfigCategoryImpl.java (renamed from src/main/java/dev/isxander/yacl/impl/ConfigCategoryImpl.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/impl/GenericBindingImpl.java (renamed from src/main/java/dev/isxander/yacl/impl/GenericBindingImpl.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/impl/OptionGroupImpl.java (renamed from src/main/java/dev/isxander/yacl/impl/OptionGroupImpl.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/impl/OptionImpl.java (renamed from src/main/java/dev/isxander/yacl/impl/OptionImpl.java)1
-rw-r--r--src/client/java/dev/isxander/yacl/impl/PlaceholderCategoryImpl.java (renamed from src/main/java/dev/isxander/yacl/impl/PlaceholderCategoryImpl.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/impl/YetAnotherConfigLibImpl.java (renamed from src/main/java/dev/isxander/yacl/impl/YetAnotherConfigLibImpl.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/impl/utils/DimensionIntegerImpl.java (renamed from src/main/java/dev/isxander/yacl/impl/utils/DimensionIntegerImpl.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/impl/utils/YACLConstants.java (renamed from src/main/java/dev/isxander/yacl/impl/utils/YACLConstants.java)0
-rw-r--r--src/client/java/dev/isxander/yacl/mixin/client/SimpleOptionAccessor.java (renamed from src/main/java/dev/isxander/yacl/mixin/SimpleOptionAccessor.java)2
-rw-r--r--src/client/resources/yet-another-config-lib.client.mixins.json (renamed from src/main/resources/yet-another-config-lib.mixins.json)2
-rw-r--r--src/main/java/dev/isxander/yacl/config/ConfigInstance.java7
-rw-r--r--src/main/java/dev/isxander/yacl/gui/controllers/EnumController.java35
-rw-r--r--src/main/resources/fabric.mod.json5
-rw-r--r--src/testmod/java/dev/isxander/yacl/test/GuiTest.java1
59 files changed, 12 insertions, 54 deletions
diff --git a/src/main/java/dev/isxander/yacl/api/Binding.java b/src/client/java/dev/isxander/yacl/api/Binding.java
index 395beb2..91158d3 100644
--- a/src/main/java/dev/isxander/yacl/api/Binding.java
+++ b/src/client/java/dev/isxander/yacl/api/Binding.java
@@ -1,7 +1,7 @@
package dev.isxander.yacl.api;
import dev.isxander.yacl.impl.GenericBindingImpl;
-import dev.isxander.yacl.mixin.SimpleOptionAccessor;
+import dev.isxander.yacl.mixin.client.SimpleOptionAccessor;
import net.minecraft.client.option.SimpleOption;
import org.apache.commons.lang3.Validate;
diff --git a/src/main/java/dev/isxander/yacl/api/ButtonOption.java b/src/client/java/dev/isxander/yacl/api/ButtonOption.java
index 1124a9a..1124a9a 100644
--- a/src/main/java/dev/isxander/yacl/api/ButtonOption.java
+++ b/src/client/java/dev/isxander/yacl/api/ButtonOption.java
diff --git a/src/main/java/dev/isxander/yacl/api/ConfigCategory.java b/src/client/java/dev/isxander/yacl/api/ConfigCategory.java
index 27c3e95..e9755dd 100644
--- a/src/main/java/dev/isxander/yacl/api/ConfigCategory.java
+++ b/src/client/java/dev/isxander/yacl/api/ConfigCategory.java
@@ -11,7 +11,6 @@ import org.jetbrains.annotations.NotNull;
import java.util.ArrayList;
import java.util.Collection;
import java.util.List;
-import java.util.function.Function;
/**
* Separates {@link Option}s or {@link OptionGroup}s into multiple distinct sections.
diff --git a/src/main/java/dev/isxander/yacl/api/Controller.java b/src/client/java/dev/isxander/yacl/api/Controller.java
index 7bf7e7f..7bf7e7f 100644
--- a/src/main/java/dev/isxander/yacl/api/Controller.java
+++ b/src/client/java/dev/isxander/yacl/api/Controller.java
diff --git a/src/main/java/dev/isxander/yacl/api/NameableEnum.java b/src/client/java/dev/isxander/yacl/api/NameableEnum.java
index 793b230..793b230 100644
--- a/src/main/java/dev/isxander/yacl/api/NameableEnum.java
+++ b/src/client/java/dev/isxander/yacl/api/NameableEnum.java
diff --git a/src/main/java/dev/isxander/yacl/api/Option.java b/src/client/java/dev/isxander/yacl/api/Option.java
index 772c816..772c816 100644
--- a/src/main/java/dev/isxander/yacl/api/Option.java
+++ b/src/client/java/dev/isxander/yacl/api/Option.java
diff --git a/src/main/java/dev/isxander/yacl/api/OptionFlag.java b/src/client/java/dev/isxander/yacl/api/OptionFlag.java
index 203a674..203a674 100644
--- a/src/main/java/dev/isxander/yacl/api/OptionFlag.java
+++ b/src/client/java/dev/isxander/yacl/api/OptionFlag.java
diff --git a/src/main/java/dev/isxander/yacl/api/OptionGroup.java b/src/client/java/dev/isxander/yacl/api/OptionGroup.java
index 3364bdf..3364bdf 100644
--- a/src/main/java/dev/isxander/yacl/api/OptionGroup.java
+++ b/src/client/java/dev/isxander/yacl/api/OptionGroup.java
diff --git a/src/main/java/dev/isxander/yacl/api/PlaceholderCategory.java b/src/client/java/dev/isxander/yacl/api/PlaceholderCategory.java
index de7441c..de7441c 100644
--- a/src/main/java/dev/isxander/yacl/api/PlaceholderCategory.java
+++ b/src/client/java/dev/isxander/yacl/api/PlaceholderCategory.java
diff --git a/src/main/java/dev/isxander/yacl/api/YetAnotherConfigLib.java b/src/client/java/dev/isxander/yacl/api/YetAnotherConfigLib.java
index a69ae4e..a69ae4e 100644
--- a/src/main/java/dev/isxander/yacl/api/YetAnotherConfigLib.java
+++ b/src/client/java/dev/isxander/yacl/api/YetAnotherConfigLib.java
diff --git a/src/main/java/dev/isxander/yacl/api/utils/Dimension.java b/src/client/java/dev/isxander/yacl/api/utils/Dimension.java
index 0de0a58..0de0a58 100644
--- a/src/main/java/dev/isxander/yacl/api/utils/Dimension.java
+++ b/src/client/java/dev/isxander/yacl/api/utils/Dimension.java
diff --git a/src/main/java/dev/isxander/yacl/api/utils/MutableDimension.java b/src/client/java/dev/isxander/yacl/api/utils/MutableDimension.java
index eff0186..eff0186 100644
--- a/src/main/java/dev/isxander/yacl/api/utils/MutableDimension.java
+++ b/src/client/java/dev/isxander/yacl/api/utils/MutableDimension.java
diff --git a/src/main/java/dev/isxander/yacl/api/utils/OptionUtils.java b/src/client/java/dev/isxander/yacl/api/utils/OptionUtils.java
index ab46b5b..ab46b5b 100644
--- a/src/main/java/dev/isxander/yacl/api/utils/OptionUtils.java
+++ b/src/client/java/dev/isxander/yacl/api/utils/OptionUtils.java
diff --git a/src/main/java/dev/isxander/yacl/gui/AbstractWidget.java b/src/client/java/dev/isxander/yacl/gui/AbstractWidget.java
index bede0ae..ffb4dec 100644
--- a/src/main/java/dev/isxander/yacl/gui/AbstractWidget.java
+++ b/src/client/java/dev/isxander/yacl/gui/AbstractWidget.java
@@ -15,7 +15,7 @@ import net.minecraft.client.sound.PositionedSoundInstance;
import net.minecraft.client.util.math.MatrixStack;
import net.minecraft.sound.SoundEvents;
-import java.awt.*;
+import java.awt.Color;
public abstract class AbstractWidget implements Element, Drawable, Selectable {
protected final MinecraftClient client = MinecraftClient.getInstance();
diff --git a/src/main/java/dev/isxander/yacl/gui/CategoryListWidget.java b/src/client/java/dev/isxander/yacl/gui/CategoryListWidget.java
index 46a9fdf..46a9fdf 100644
--- a/src/main/java/dev/isxander/yacl/gui/CategoryListWidget.java
+++ b/src/client/java/dev/isxander/yacl/gui/CategoryListWidget.java
diff --git a/src/main/java/dev/isxander/yacl/gui/CategoryWidget.java b/src/client/java/dev/isxander/yacl/gui/CategoryWidget.java
index 3c5d8d2..3c5d8d2 100644
--- a/src/main/java/dev/isxander/yacl/gui/CategoryWidget.java
+++ b/src/client/java/dev/isxander/yacl/gui/CategoryWidget.java
diff --git a/src/main/java/dev/isxander/yacl/gui/LowProfileButtonWidget.java b/src/client/java/dev/isxander/yacl/gui/LowProfileButtonWidget.java
index 4823428..9fa01a7 100644
--- a/src/main/java/dev/isxander/yacl/gui/LowProfileButtonWidget.java
+++ b/src/client/java/dev/isxander/yacl/gui/LowProfileButtonWidget.java
@@ -9,7 +9,7 @@ import net.minecraft.util.math.MathHelper;
public class LowProfileButtonWidget extends ButtonWidget {
public LowProfileButtonWidget(int x, int y, int width, int height, Text message, PressAction onPress) {
- super(x, y, width, height, message, onPress, ButtonWidget.DEFAULT_NARRATION_SUPPLIER);
+ super(x, y, width, height, message, onPress, DEFAULT_NARRATION_SUPPLIER);
}
public LowProfileButtonWidget(int x, int y, int width, int height, Text message, PressAction onPress, Tooltip tooltip) {
diff --git a/src/main/java/dev/isxander/yacl/gui/OptionListWidget.java b/src/client/java/dev/isxander/yacl/gui/OptionListWidget.java
index eed3aff..eed3aff 100644
--- a/src/main/java/dev/isxander/yacl/gui/OptionListWidget.java
+++ b/src/client/java/dev/isxander/yacl/gui/OptionListWidget.java
diff --git a/src/main/java/dev/isxander/yacl/gui/RequireRestartScreen.java b/src/client/java/dev/isxander/yacl/gui/RequireRestartScreen.java
index 3c46738..3c46738 100644
--- a/src/main/java/dev/isxander/yacl/gui/RequireRestartScreen.java
+++ b/src/client/java/dev/isxander/yacl/gui/RequireRestartScreen.java
diff --git a/src/main/java/dev/isxander/yacl/gui/SearchFieldWidget.java b/src/client/java/dev/isxander/yacl/gui/SearchFieldWidget.java
index 5b7c9dc..5b7c9dc 100644
--- a/src/main/java/dev/isxander/yacl/gui/SearchFieldWidget.java
+++ b/src/client/java/dev/isxander/yacl/gui/SearchFieldWidget.java
diff --git a/src/main/java/dev/isxander/yacl/gui/TextScaledButtonWidget.java b/src/client/java/dev/isxander/yacl/gui/TextScaledButtonWidget.java
index 9f153f6..2d0a99c 100644
--- a/src/main/java/dev/isxander/yacl/gui/TextScaledButtonWidget.java
+++ b/src/client/java/dev/isxander/yacl/gui/TextScaledButtonWidget.java
@@ -13,7 +13,7 @@ public class TextScaledButtonWidget extends ButtonWidget {
public float textScale;
public TextScaledButtonWidget(int x, int y, int width, int height, float textScale, Text message, PressAction onPress) {
- super(x, y, width, height, message, onPress, ButtonWidget.DEFAULT_NARRATION_SUPPLIER);
+ super(x, y, width, height, message, onPress, DEFAULT_NARRATION_SUPPLIER);
this.textScale = textScale;
}
diff --git a/src/main/java/dev/isxander/yacl/gui/TooltipButtonWidget.java b/src/client/java/dev/isxander/yacl/gui/TooltipButtonWidget.java
index 706765a..b034f4b 100644
--- a/src/main/java/dev/isxander/yacl/gui/TooltipButtonWidget.java
+++ b/src/client/java/dev/isxander/yacl/gui/TooltipButtonWidget.java
@@ -13,7 +13,7 @@ public class TooltipButtonWidget extends ButtonWidget {
protected MultilineText wrappedDescription;
public TooltipButtonWidget(Screen screen, int x, int y, int width, int height, Text message, Text tooltip, PressAction onPress) {
- super(x, y, width, height, message, onPress, ButtonWidget.DEFAULT_NARRATION_SUPPLIER);
+ super(x, y, width, height, message, onPress, DEFAULT_NARRATION_SUPPLIER);
this.screen = screen;
setTooltip(tooltip);
}
diff --git a/src/main/java/dev/isxander/yacl/gui/YACLScreen.java b/src/client/java/dev/isxander/yacl/gui/YACLScreen.java
index e36c8e8..e36c8e8 100644
--- a/src/main/java/dev/isxander/yacl/gui/YACLScreen.java
+++ b/src/client/java/dev/isxander/yacl/gui/YACLScreen.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/ActionController.java b/src/client/java/dev/isxander/yacl/gui/controllers/ActionController.java
index b8e2cd1..b8e2cd1 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/ActionController.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/ActionController.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/BooleanController.java b/src/client/java/dev/isxander/yacl/gui/controllers/BooleanController.java
index 7037ff5..7037ff5 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/BooleanController.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/BooleanController.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/ColorController.java b/src/client/java/dev/isxander/yacl/gui/controllers/ColorController.java
index 0a83fbe..a68475d 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/ColorController.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/ColorController.java
@@ -14,7 +14,7 @@ import net.minecraft.text.MutableText;
import net.minecraft.text.Text;
import net.minecraft.util.Formatting;
-import java.awt.*;
+import java.awt.Color;
import java.util.List;
/**
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/ControllerWidget.java b/src/client/java/dev/isxander/yacl/gui/controllers/ControllerWidget.java
index c7f9e97..c7f9e97 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/ControllerWidget.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/ControllerWidget.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/LabelController.java b/src/client/java/dev/isxander/yacl/gui/controllers/LabelController.java
index 8369680..8369680 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/LabelController.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/LabelController.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/TickBoxController.java b/src/client/java/dev/isxander/yacl/gui/controllers/TickBoxController.java
index 340983d..340983d 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/TickBoxController.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/TickBoxController.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/cycling/CyclingControllerElement.java b/src/client/java/dev/isxander/yacl/gui/controllers/cycling/CyclingControllerElement.java
index ab0a9c3..ab0a9c3 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/cycling/CyclingControllerElement.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/cycling/CyclingControllerElement.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/cycling/CyclingListController.java b/src/client/java/dev/isxander/yacl/gui/controllers/cycling/CyclingListController.java
index 3b14066..3b14066 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/cycling/CyclingListController.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/cycling/CyclingListController.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/cycling/EnumController.java b/src/client/java/dev/isxander/yacl/gui/controllers/cycling/EnumController.java
index bc9f46d..bc9f46d 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/cycling/EnumController.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/cycling/EnumController.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/cycling/ICyclingController.java b/src/client/java/dev/isxander/yacl/gui/controllers/cycling/ICyclingController.java
index 081b572..081b572 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/cycling/ICyclingController.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/cycling/ICyclingController.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/package-info.java b/src/client/java/dev/isxander/yacl/gui/controllers/package-info.java
index 12ce86b..12ce86b 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/package-info.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/package-info.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/slider/DoubleSliderController.java b/src/client/java/dev/isxander/yacl/gui/controllers/slider/DoubleSliderController.java
index b530e8c..b530e8c 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/slider/DoubleSliderController.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/slider/DoubleSliderController.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/slider/FloatSliderController.java b/src/client/java/dev/isxander/yacl/gui/controllers/slider/FloatSliderController.java
index d7c203e..d7c203e 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/slider/FloatSliderController.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/slider/FloatSliderController.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/slider/ISliderController.java b/src/client/java/dev/isxander/yacl/gui/controllers/slider/ISliderController.java
index aa3c18f..aa3c18f 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/slider/ISliderController.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/slider/ISliderController.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/slider/IntegerSliderController.java b/src/client/java/dev/isxander/yacl/gui/controllers/slider/IntegerSliderController.java
index a8bca7c..a8bca7c 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/slider/IntegerSliderController.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/slider/IntegerSliderController.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/slider/LongSliderController.java b/src/client/java/dev/isxander/yacl/gui/controllers/slider/LongSliderController.java
index 50559d5..50559d5 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/slider/LongSliderController.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/slider/LongSliderController.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/slider/SliderControllerElement.java b/src/client/java/dev/isxander/yacl/gui/controllers/slider/SliderControllerElement.java
index 913cc00..913cc00 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/slider/SliderControllerElement.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/slider/SliderControllerElement.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/slider/package-info.java b/src/client/java/dev/isxander/yacl/gui/controllers/slider/package-info.java
index bff0d57..bff0d57 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/slider/package-info.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/slider/package-info.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/string/IStringController.java b/src/client/java/dev/isxander/yacl/gui/controllers/string/IStringController.java
index 41843b8..41843b8 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/string/IStringController.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/string/IStringController.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/string/StringController.java b/src/client/java/dev/isxander/yacl/gui/controllers/string/StringController.java
index 0caaa93..0caaa93 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/string/StringController.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/string/StringController.java
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/string/StringControllerElement.java b/src/client/java/dev/isxander/yacl/gui/controllers/string/StringControllerElement.java
index 0c3b7c9..0c3b7c9 100644
--- a/src/main/java/dev/isxander/yacl/gui/controllers/string/StringControllerElement.java
+++ b/src/client/java/dev/isxander/yacl/gui/controllers/string/StringControllerElement.java
diff --git a/src/main/java/dev/isxander/yacl/impl/ButtonOptionImpl.java b/src/client/java/dev/isxander/yacl/impl/ButtonOptionImpl.java
index dcb9c7a..dcb9c7a 100644
--- a/src/main/java/dev/isxander/yacl/impl/ButtonOptionImpl.java
+++ b/src/client/java/dev/isxander/yacl/impl/ButtonOptionImpl.java
diff --git a/src/main/java/dev/isxander/yacl/impl/ConfigCategoryImpl.java b/src/client/java/dev/isxander/yacl/impl/ConfigCategoryImpl.java
index 971fecf..971fecf 100644
--- a/src/main/java/dev/isxander/yacl/impl/ConfigCategoryImpl.java
+++ b/src/client/java/dev/isxander/yacl/impl/ConfigCategoryImpl.java
diff --git a/src/main/java/dev/isxander/yacl/impl/GenericBindingImpl.java b/src/client/java/dev/isxander/yacl/impl/GenericBindingImpl.java
index 1867bb6..1867bb6 100644
--- a/src/main/java/dev/isxander/yacl/impl/GenericBindingImpl.java
+++ b/src/client/java/dev/isxander/yacl/impl/GenericBindingImpl.java
diff --git a/src/main/java/dev/isxander/yacl/impl/OptionGroupImpl.java b/src/client/java/dev/isxander/yacl/impl/OptionGroupImpl.java
index 58bc96b..58bc96b 100644
--- a/src/main/java/dev/isxander/yacl/impl/OptionGroupImpl.java
+++ b/src/client/java/dev/isxander/yacl/impl/OptionGroupImpl.java
diff --git a/src/main/java/dev/isxander/yacl/impl/OptionImpl.java b/src/client/java/dev/isxander/yacl/impl/OptionImpl.java
index c76f115..90158c7 100644
--- a/src/main/java/dev/isxander/yacl/impl/OptionImpl.java
+++ b/src/client/java/dev/isxander/yacl/impl/OptionImpl.java
@@ -6,7 +6,6 @@ import dev.isxander.yacl.api.Controller;
import dev.isxander.yacl.api.Option;
import dev.isxander.yacl.api.OptionFlag;
import net.minecraft.text.Text;
-import org.jetbrains.annotations.ApiStatus;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
diff --git a/src/main/java/dev/isxander/yacl/impl/PlaceholderCategoryImpl.java b/src/client/java/dev/isxander/yacl/impl/PlaceholderCategoryImpl.java
index a5180ad..a5180ad 100644
--- a/src/main/java/dev/isxander/yacl/impl/PlaceholderCategoryImpl.java
+++ b/src/client/java/dev/isxander/yacl/impl/PlaceholderCategoryImpl.java
diff --git a/src/main/java/dev/isxander/yacl/impl/YetAnotherConfigLibImpl.java b/src/client/java/dev/isxander/yacl/impl/YetAnotherConfigLibImpl.java
index eb23eac..eb23eac 100644
--- a/src/main/java/dev/isxander/yacl/impl/YetAnotherConfigLibImpl.java
+++ b/src/client/java/dev/isxander/yacl/impl/YetAnotherConfigLibImpl.java
diff --git a/src/main/java/dev/isxander/yacl/impl/utils/DimensionIntegerImpl.java b/src/client/java/dev/isxander/yacl/impl/utils/DimensionIntegerImpl.java
index 6c7508d..6c7508d 100644
--- a/src/main/java/dev/isxander/yacl/impl/utils/DimensionIntegerImpl.java
+++ b/src/client/java/dev/isxander/yacl/impl/utils/DimensionIntegerImpl.java
diff --git a/src/main/java/dev/isxander/yacl/impl/utils/YACLConstants.java b/src/client/java/dev/isxander/yacl/impl/utils/YACLConstants.java
index 3d382d4..3d382d4 100644
--- a/src/main/java/dev/isxander/yacl/impl/utils/YACLConstants.java
+++ b/src/client/java/dev/isxander/yacl/impl/utils/YACLConstants.java
diff --git a/src/main/java/dev/isxander/yacl/mixin/SimpleOptionAccessor.java b/src/client/java/dev/isxander/yacl/mixin/client/SimpleOptionAccessor.java
index 9207225..a48c808 100644
--- a/src/main/java/dev/isxander/yacl/mixin/SimpleOptionAccessor.java
+++ b/src/client/java/dev/isxander/yacl/mixin/client/SimpleOptionAccessor.java
@@ -1,4 +1,4 @@
-package dev.isxander.yacl.mixin;
+package dev.isxander.yacl.mixin.client;
import net.minecraft.client.option.SimpleOption;
import org.spongepowered.asm.mixin.Mixin;
diff --git a/src/main/resources/yet-another-config-lib.mixins.json b/src/client/resources/yet-another-config-lib.client.mixins.json
index cb96c48..2367a67 100644
--- a/src/main/resources/yet-another-config-lib.mixins.json
+++ b/src/client/resources/yet-another-config-lib.client.mixins.json
@@ -1,6 +1,6 @@
{
"required": true,
- "package": "dev.isxander.yacl.mixin",
+ "package": "dev.isxander.yacl.mixin.client",
"compatibilityLevel": "JAVA_17",
"injectors": {
"defaultRequire": 1
diff --git a/src/main/java/dev/isxander/yacl/config/ConfigInstance.java b/src/main/java/dev/isxander/yacl/config/ConfigInstance.java
index a7c013c..8795eb1 100644
--- a/src/main/java/dev/isxander/yacl/config/ConfigInstance.java
+++ b/src/main/java/dev/isxander/yacl/config/ConfigInstance.java
@@ -1,9 +1,6 @@
package dev.isxander.yacl.config;
-import dev.isxander.yacl.api.YetAnotherConfigLib;
-
import java.lang.reflect.InvocationTargetException;
-import java.util.function.BiFunction;
/**
* Responsible for handing the actual config data type.
@@ -46,10 +43,6 @@ public abstract class ConfigInstance<T> {
return this.configClass;
}
- public YetAnotherConfigLib buildConfig(BiFunction<ConfigInstance<T>, YetAnotherConfigLib.Builder, YetAnotherConfigLib.Builder> builder) {
- return builder.apply(this, YetAnotherConfigLib.createBuilder().save(this::save)).build();
- }
-
public abstract void save();
public abstract void load();
}
diff --git a/src/main/java/dev/isxander/yacl/gui/controllers/EnumController.java b/src/main/java/dev/isxander/yacl/gui/controllers/EnumController.java
deleted file mode 100644
index ebad4ae..0000000
--- a/src/main/java/dev/isxander/yacl/gui/controllers/EnumController.java
+++ /dev/null
@@ -1,35 +0,0 @@
-package dev.isxander.yacl.gui.controllers;
-
-import dev.isxander.yacl.api.NameableEnum;
-import dev.isxander.yacl.api.Option;
-import dev.isxander.yacl.gui.controllers.cycling.CyclingListController;
-import net.minecraft.text.Text;
-import net.minecraft.util.TranslatableOption;
-
-import java.util.Arrays;
-import java.util.function.Function;
-
-@Deprecated
-public class EnumController<T extends Enum<T>> extends CyclingListController<T> {
- public static <T extends Enum<T>> Function<T, Text> getDefaultFormatter() {
- return value -> {
- if (value instanceof NameableEnum nameableEnum)
- return nameableEnum.getDisplayName();
- if (value instanceof TranslatableOption translatableOption)
- return translatableOption.getText();
- return Text.of(value.toString());
- };
- }
-
- public EnumController(Option<T> option) {
- this(option, getDefaultFormatter());
- }
-
- public EnumController(Option<T> option, Function<T, Text> valueFormatter) {
- this(option, valueFormatter, option.typeClass().getEnumConstants());
- }
-
- public EnumController(Option<T> option, Function<T, Text> valueFormatter, T[] availableValues) {
- super(option, Arrays.asList(availableValues), valueFormatter);
- }
-}
diff --git a/src/main/resources/fabric.mod.json b/src/main/resources/fabric.mod.json
index 234a281..0bd51c5 100644
--- a/src/main/resources/fabric.mod.json
+++ b/src/main/resources/fabric.mod.json
@@ -25,7 +25,10 @@
"fabric-resource-loader-v0": "*"
},
"mixins": [
- "yet-another-config-lib.mixins.json"
+ {
+ "config": "yet-another-config-lib.client.mixins.json",
+ "environment": "client"
+ }
],
"accessWidener": "yacl.accesswidener",
"custom": {
diff --git a/src/testmod/java/dev/isxander/yacl/test/GuiTest.java b/src/testmod/java/dev/isxander/yacl/test/GuiTest.java
index d50164d..2944d69 100644
--- a/src/testmod/java/dev/isxander/yacl/test/GuiTest.java
+++ b/src/testmod/java/dev/isxander/yacl/test/GuiTest.java
@@ -2,7 +2,6 @@ package dev.isxander.yacl.test;
import dev.isxander.yacl.api.*;
import dev.isxander.yacl.gui.RequireRestartScreen;
-import dev.isxander.yacl.gui.controllers.*;
import dev.isxander.yacl.gui.controllers.cycling.EnumController;
import dev.isxander.yacl.gui.controllers.slider.DoubleSliderController;
import dev.isxander.yacl.gui.controllers.slider.FloatSliderController;