From 3e36feeef60e56ef8cb7f737ac8eeab9fbcd6abb Mon Sep 17 00:00:00 2001 From: isXander Date: Sat, 3 Jun 2023 23:10:03 +0100 Subject: Change package and modid to yacl3 and yet_another_config_lib_3 respectively --- .../controller/AbstractControllerBuilderImpl.java | 12 +++++ .../controller/BooleanControllerBuilderImpl.java | 56 ++++++++++++++++++++++ .../controller/ColorControllerBuilderImpl.java | 27 +++++++++++ .../CyclingListControllerBuilderImpl.java | 43 +++++++++++++++++ .../DoubleFieldControllerBuilderImpl.java | 50 +++++++++++++++++++ .../DoubleSliderControllerBuilderImpl.java | 43 +++++++++++++++++ .../impl/controller/EnumControllerBuilderImpl.java | 35 ++++++++++++++ .../FloatFieldControllerBuilderImpl.java | 50 +++++++++++++++++++ .../FloatSliderControllerBuilderImpl.java | 43 +++++++++++++++++ .../IntegerFieldControllerBuilderImpl.java | 50 +++++++++++++++++++ .../IntegerSliderControllerBuilderImpl.java | 43 +++++++++++++++++ .../controller/LongFieldControllerBuilderImpl.java | 50 +++++++++++++++++++ .../LongSliderControllerBuilderImpl.java | 43 +++++++++++++++++ .../controller/StringControllerBuilderImpl.java | 17 +++++++ .../controller/TickBoxControllerBuilderImpl.java | 17 +++++++ 15 files changed, 579 insertions(+) create mode 100644 common/src/main/java/dev/isxander/yacl3/impl/controller/AbstractControllerBuilderImpl.java create mode 100644 common/src/main/java/dev/isxander/yacl3/impl/controller/BooleanControllerBuilderImpl.java create mode 100644 common/src/main/java/dev/isxander/yacl3/impl/controller/ColorControllerBuilderImpl.java create mode 100644 common/src/main/java/dev/isxander/yacl3/impl/controller/CyclingListControllerBuilderImpl.java create mode 100644 common/src/main/java/dev/isxander/yacl3/impl/controller/DoubleFieldControllerBuilderImpl.java create mode 100644 common/src/main/java/dev/isxander/yacl3/impl/controller/DoubleSliderControllerBuilderImpl.java create mode 100644 common/src/main/java/dev/isxander/yacl3/impl/controller/EnumControllerBuilderImpl.java create mode 100644 common/src/main/java/dev/isxander/yacl3/impl/controller/FloatFieldControllerBuilderImpl.java create mode 100644 common/src/main/java/dev/isxander/yacl3/impl/controller/FloatSliderControllerBuilderImpl.java create mode 100644 common/src/main/java/dev/isxander/yacl3/impl/controller/IntegerFieldControllerBuilderImpl.java create mode 100644 common/src/main/java/dev/isxander/yacl3/impl/controller/IntegerSliderControllerBuilderImpl.java create mode 100644 common/src/main/java/dev/isxander/yacl3/impl/controller/LongFieldControllerBuilderImpl.java create mode 100644 common/src/main/java/dev/isxander/yacl3/impl/controller/LongSliderControllerBuilderImpl.java create mode 100644 common/src/main/java/dev/isxander/yacl3/impl/controller/StringControllerBuilderImpl.java create mode 100644 common/src/main/java/dev/isxander/yacl3/impl/controller/TickBoxControllerBuilderImpl.java (limited to 'common/src/main/java/dev/isxander/yacl3/impl/controller') diff --git a/common/src/main/java/dev/isxander/yacl3/impl/controller/AbstractControllerBuilderImpl.java b/common/src/main/java/dev/isxander/yacl3/impl/controller/AbstractControllerBuilderImpl.java new file mode 100644 index 0000000..66c025a --- /dev/null +++ b/common/src/main/java/dev/isxander/yacl3/impl/controller/AbstractControllerBuilderImpl.java @@ -0,0 +1,12 @@ +package dev.isxander.yacl3.impl.controller; + +import dev.isxander.yacl3.api.Option; +import dev.isxander.yacl3.api.controller.ControllerBuilder; + +public abstract class AbstractControllerBuilderImpl implements ControllerBuilder { + protected final Option option; + + protected AbstractControllerBuilderImpl(Option option) { + this.option = option; + } +} diff --git a/common/src/main/java/dev/isxander/yacl3/impl/controller/BooleanControllerBuilderImpl.java b/common/src/main/java/dev/isxander/yacl3/impl/controller/BooleanControllerBuilderImpl.java new file mode 100644 index 0000000..208f78e --- /dev/null +++ b/common/src/main/java/dev/isxander/yacl3/impl/controller/BooleanControllerBuilderImpl.java @@ -0,0 +1,56 @@ +package dev.isxander.yacl3.impl.controller; + +import dev.isxander.yacl3.api.Controller; +import dev.isxander.yacl3.api.Option; +import dev.isxander.yacl3.api.controller.BooleanControllerBuilder; +import dev.isxander.yacl3.gui.controllers.BooleanController; +import net.minecraft.network.chat.Component; +import org.apache.commons.lang3.Validate; + +import java.util.function.Function; + +public class BooleanControllerBuilderImpl extends AbstractControllerBuilderImpl implements BooleanControllerBuilder { + private boolean coloured = false; + private Function formatter = BooleanController.ON_OFF_FORMATTER; + + public BooleanControllerBuilderImpl(Option option) { + super(option); + } + + @Override + public BooleanControllerBuilder coloured(boolean coloured) { + this.coloured = coloured; + return this; + } + + @Override + public BooleanControllerBuilder valueFormatter(Function formatter) { + Validate.notNull(formatter); + + this.formatter = formatter; + return this; + } + + @Override + public BooleanControllerBuilder onOffFormatter() { + this.formatter = BooleanController.ON_OFF_FORMATTER; + return this; + } + + @Override + public BooleanControllerBuilder yesNoFormatter() { + this.formatter = BooleanController.YES_NO_FORMATTER; + return this; + } + + @Override + public BooleanControllerBuilder trueFalseFormatter() { + this.formatter = BooleanController.TRUE_FALSE_FORMATTER; + return this; + } + + @Override + public Controller build() { + return new BooleanController(option, formatter, coloured); + } +} diff --git a/common/src/main/java/dev/isxander/yacl3/impl/controller/ColorControllerBuilderImpl.java b/common/src/main/java/dev/isxander/yacl3/impl/controller/ColorControllerBuilderImpl.java new file mode 100644 index 0000000..9412165 --- /dev/null +++ b/common/src/main/java/dev/isxander/yacl3/impl/controller/ColorControllerBuilderImpl.java @@ -0,0 +1,27 @@ +package dev.isxander.yacl3.impl.controller; + +import dev.isxander.yacl3.api.Controller; +import dev.isxander.yacl3.api.Option; +import dev.isxander.yacl3.api.controller.ColorControllerBuilder; +import dev.isxander.yacl3.gui.controllers.ColorController; + +import java.awt.Color; + +public class ColorControllerBuilderImpl extends AbstractControllerBuilderImpl implements ColorControllerBuilder { + private boolean allowAlpha = false; + + public ColorControllerBuilderImpl(Option option) { + super(option); + } + + @Override + public ColorControllerBuilder allowAlpha(boolean allowAlpha) { + this.allowAlpha = allowAlpha; + return this; + } + + @Override + public Controller build() { + return new ColorController(option, allowAlpha); + } +} diff --git a/common/src/main/java/dev/isxander/yacl3/impl/controller/CyclingListControllerBuilderImpl.java b/common/src/main/java/dev/isxander/yacl3/impl/controller/CyclingListControllerBuilderImpl.java new file mode 100644 index 0000000..63045f2 --- /dev/null +++ b/common/src/main/java/dev/isxander/yacl3/impl/controller/CyclingListControllerBuilderImpl.java @@ -0,0 +1,43 @@ +package dev.isxander.yacl3.impl.controller; + +import com.google.common.collect.ImmutableList; +import dev.isxander.yacl3.api.Controller; +import dev.isxander.yacl3.api.Option; +import dev.isxander.yacl3.api.controller.CyclingListControllerBuilder; +import dev.isxander.yacl3.gui.controllers.cycling.CyclingListController; +import net.minecraft.network.chat.Component; + +import java.util.function.Function; + +public final class CyclingListControllerBuilderImpl extends AbstractControllerBuilderImpl implements CyclingListControllerBuilder { + private Iterable values; + private Function formatter = null; + + public CyclingListControllerBuilderImpl(Option option) { + super(option); + } + + @Override + public CyclingListControllerBuilder values(Iterable values) { + this.values = values; + return this; + } + + @SafeVarargs + @Override + public final CyclingListControllerBuilder values(T... values) { + this.values = ImmutableList.copyOf(values); + return this; + } + + @Override + public CyclingListControllerBuilder valueFormatter(Function formatter) { + this.formatter = formatter; + return this; + } + + @Override + public Controller build() { + return new CyclingListController<>(option, values, formatter); + } +} diff --git a/common/src/main/java/dev/isxander/yacl3/impl/controller/DoubleFieldControllerBuilderImpl.java b/common/src/main/java/dev/isxander/yacl3/impl/controller/DoubleFieldControllerBuilderImpl.java new file mode 100644 index 0000000..56e1d44 --- /dev/null +++ b/common/src/main/java/dev/isxander/yacl3/impl/controller/DoubleFieldControllerBuilderImpl.java @@ -0,0 +1,50 @@ +package dev.isxander.yacl3.impl.controller; + +import dev.isxander.yacl3.api.Controller; +import dev.isxander.yacl3.api.Option; +import dev.isxander.yacl3.api.controller.DoubleFieldControllerBuilder; +import dev.isxander.yacl3.gui.controllers.slider.DoubleSliderController; +import dev.isxander.yacl3.gui.controllers.string.number.DoubleFieldController; +import net.minecraft.network.chat.Component; + +import java.util.function.Function; + +public class DoubleFieldControllerBuilderImpl extends AbstractControllerBuilderImpl implements DoubleFieldControllerBuilder { + private double min = Double.MIN_VALUE; + private double max = Double.MAX_VALUE; + private Function formatter = DoubleSliderController.DEFAULT_FORMATTER; + + public DoubleFieldControllerBuilderImpl(Option option) { + super(option); + } + + @Override + public DoubleFieldControllerBuilder min(Double min) { + this.min = min; + return this; + } + + @Override + public DoubleFieldControllerBuilder max(Double max) { + this.max = max; + return this; + } + + @Override + public DoubleFieldControllerBuilder range(Double min, Double max) { + this.min = min; + this.max = max; + return this; + } + + @Override + public DoubleFieldControllerBuilder valueFormatter(Function formatter) { + this.formatter = formatter; + return this; + } + + @Override + public Controller build() { + return new DoubleFieldController(option, min, max, formatter); + } +} diff --git a/common/src/main/java/dev/isxander/yacl3/impl/controller/DoubleSliderControllerBuilderImpl.java b/common/src/main/java/dev/isxander/yacl3/impl/controller/DoubleSliderControllerBuilderImpl.java new file mode 100644 index 0000000..a636abf --- /dev/null +++ b/common/src/main/java/dev/isxander/yacl3/impl/controller/DoubleSliderControllerBuilderImpl.java @@ -0,0 +1,43 @@ +package dev.isxander.yacl3.impl.controller; + +import dev.isxander.yacl3.api.Controller; +import dev.isxander.yacl3.api.Option; +import dev.isxander.yacl3.api.controller.DoubleSliderControllerBuilder; +import dev.isxander.yacl3.gui.controllers.slider.DoubleSliderController; +import net.minecraft.network.chat.Component; + +import java.util.function.Function; + +public class DoubleSliderControllerBuilderImpl extends AbstractControllerBuilderImpl implements DoubleSliderControllerBuilder { + private double min, max; + private double step; + private Function formatter = DoubleSliderController.DEFAULT_FORMATTER; + + public DoubleSliderControllerBuilderImpl(Option option) { + super(option); + } + + @Override + public DoubleSliderControllerBuilder range(Double min, Double max) { + this.min = min; + this.max = max; + return this; + } + + @Override + public DoubleSliderControllerBuilder step(Double step) { + this.step = step; + return this; + } + + @Override + public DoubleSliderControllerBuilder valueFormatter(Function formatter) { + this.formatter = formatter; + return this; + } + + @Override + public Controller build() { + return new DoubleSliderController(option, min, max, step, formatter); + } +} diff --git a/common/src/main/java/dev/isxander/yacl3/impl/controller/EnumControllerBuilderImpl.java b/common/src/main/java/dev/isxander/yacl3/impl/controller/EnumControllerBuilderImpl.java new file mode 100644 index 0000000..3237dbf --- /dev/null +++ b/common/src/main/java/dev/isxander/yacl3/impl/controller/EnumControllerBuilderImpl.java @@ -0,0 +1,35 @@ +package dev.isxander.yacl3.impl.controller; + +import dev.isxander.yacl3.api.Controller; +import dev.isxander.yacl3.api.Option; +import dev.isxander.yacl3.api.controller.EnumControllerBuilder; +import dev.isxander.yacl3.gui.controllers.cycling.EnumController; +import net.minecraft.network.chat.Component; + +import java.util.function.Function; + +public class EnumControllerBuilderImpl> extends AbstractControllerBuilderImpl implements EnumControllerBuilder { + private Class enumClass; + private Function formatter = EnumController.getDefaultFormatter(); + + public EnumControllerBuilderImpl(Option option) { + super(option); + } + + @Override + public EnumControllerBuilder enumClass(Class enumClass) { + this.enumClass = enumClass; + return this; + } + + @Override + public EnumControllerBuilder valueFormatter(Function formatter) { + this.formatter = formatter; + return this; + } + + @Override + public Controller build() { + return new EnumController<>(option, formatter, enumClass.getEnumConstants()); + } +} diff --git a/common/src/main/java/dev/isxander/yacl3/impl/controller/FloatFieldControllerBuilderImpl.java b/common/src/main/java/dev/isxander/yacl3/impl/controller/FloatFieldControllerBuilderImpl.java new file mode 100644 index 0000000..09dbce0 --- /dev/null +++ b/common/src/main/java/dev/isxander/yacl3/impl/controller/FloatFieldControllerBuilderImpl.java @@ -0,0 +1,50 @@ +package dev.isxander.yacl3.impl.controller; + +import dev.isxander.yacl3.api.Controller; +import dev.isxander.yacl3.api.Option; +import dev.isxander.yacl3.api.controller.FloatFieldControllerBuilder; +import dev.isxander.yacl3.gui.controllers.slider.FloatSliderController; +import dev.isxander.yacl3.gui.controllers.string.number.FloatFieldController; +import net.minecraft.network.chat.Component; + +import java.util.function.Function; + +public class FloatFieldControllerBuilderImpl extends AbstractControllerBuilderImpl implements FloatFieldControllerBuilder { + private float min = Float.MIN_VALUE; + private float max = Float.MAX_VALUE; + private Function formatter = FloatSliderController.DEFAULT_FORMATTER; + + public FloatFieldControllerBuilderImpl(Option option) { + super(option); + } + + @Override + public FloatFieldControllerBuilder min(Float min) { + this.min = min; + return this; + } + + @Override + public FloatFieldControllerBuilder max(Float max) { + this.max = max; + return this; + } + + @Override + public FloatFieldControllerBuilder range(Float min, Float max) { + this.min = min; + this.max = max; + return this; + } + + @Override + public FloatFieldControllerBuilder valueFormatter(Function formatter) { + this.formatter = formatter; + return this; + } + + @Override + public Controller build() { + return new FloatFieldController(option, min, max, formatter); + } +} diff --git a/common/src/main/java/dev/isxander/yacl3/impl/controller/FloatSliderControllerBuilderImpl.java b/common/src/main/java/dev/isxander/yacl3/impl/controller/FloatSliderControllerBuilderImpl.java new file mode 100644 index 0000000..c9699fb --- /dev/null +++ b/common/src/main/java/dev/isxander/yacl3/impl/controller/FloatSliderControllerBuilderImpl.java @@ -0,0 +1,43 @@ +package dev.isxander.yacl3.impl.controller; + +import dev.isxander.yacl3.api.Controller; +import dev.isxander.yacl3.api.Option; +import dev.isxander.yacl3.api.controller.FloatSliderControllerBuilder; +import dev.isxander.yacl3.gui.controllers.slider.FloatSliderController; +import net.minecraft.network.chat.Component; + +import java.util.function.Function; + +public class FloatSliderControllerBuilderImpl extends AbstractControllerBuilderImpl implements FloatSliderControllerBuilder { + private float min, max; + private float step; + private Function formatter = FloatSliderController.DEFAULT_FORMATTER; + + public FloatSliderControllerBuilderImpl(Option option) { + super(option); + } + + @Override + public FloatSliderControllerBuilder range(Float min, Float max) { + this.min = min; + this.max = max; + return this; + } + + @Override + public FloatSliderControllerBuilder step(Float step) { + this.step = step; + return this; + } + + @Override + public FloatSliderControllerBuilder valueFormatter(Function formatter) { + this.formatter = formatter; + return this; + } + + @Override + public Controller build() { + return new FloatSliderController(option, min, max, step, formatter); + } +} diff --git a/common/src/main/java/dev/isxander/yacl3/impl/controller/IntegerFieldControllerBuilderImpl.java b/common/src/main/java/dev/isxander/yacl3/impl/controller/IntegerFieldControllerBuilderImpl.java new file mode 100644 index 0000000..73b51a0 --- /dev/null +++ b/common/src/main/java/dev/isxander/yacl3/impl/controller/IntegerFieldControllerBuilderImpl.java @@ -0,0 +1,50 @@ +package dev.isxander.yacl3.impl.controller; + +import dev.isxander.yacl3.api.Controller; +import dev.isxander.yacl3.api.Option; +import dev.isxander.yacl3.api.controller.IntegerFieldControllerBuilder; +import dev.isxander.yacl3.gui.controllers.slider.IntegerSliderController; +import dev.isxander.yacl3.gui.controllers.string.number.IntegerFieldController; +import net.minecraft.network.chat.Component; + +import java.util.function.Function; + +public class IntegerFieldControllerBuilderImpl extends AbstractControllerBuilderImpl implements IntegerFieldControllerBuilder { + private int min = Integer.MIN_VALUE; + private int max = Integer.MAX_VALUE; + private Function formatter = IntegerSliderController.DEFAULT_FORMATTER; + + public IntegerFieldControllerBuilderImpl(Option option) { + super(option); + } + + @Override + public IntegerFieldControllerBuilder min(Integer min) { + this.min = min; + return this; + } + + @Override + public IntegerFieldControllerBuilder max(Integer max) { + this.max = max; + return this; + } + + @Override + public IntegerFieldControllerBuilder range(Integer min, Integer max) { + this.min = min; + this.max = max; + return this; + } + + @Override + public IntegerFieldControllerBuilder valueFormatter(Function formatter) { + this.formatter = formatter; + return this; + } + + @Override + public Controller build() { + return new IntegerFieldController(option, min, max, formatter); + } +} diff --git a/common/src/main/java/dev/isxander/yacl3/impl/controller/IntegerSliderControllerBuilderImpl.java b/common/src/main/java/dev/isxander/yacl3/impl/controller/IntegerSliderControllerBuilderImpl.java new file mode 100644 index 0000000..106c22a --- /dev/null +++ b/common/src/main/java/dev/isxander/yacl3/impl/controller/IntegerSliderControllerBuilderImpl.java @@ -0,0 +1,43 @@ +package dev.isxander.yacl3.impl.controller; + +import dev.isxander.yacl3.api.Controller; +import dev.isxander.yacl3.api.Option; +import dev.isxander.yacl3.api.controller.IntegerSliderControllerBuilder; +import dev.isxander.yacl3.gui.controllers.slider.IntegerSliderController; +import net.minecraft.network.chat.Component; + +import java.util.function.Function; + +public class IntegerSliderControllerBuilderImpl extends AbstractControllerBuilderImpl implements IntegerSliderControllerBuilder { + private int min, max; + private int step; + private Function formatter = IntegerSliderController.DEFAULT_FORMATTER; + + public IntegerSliderControllerBuilderImpl(Option option) { + super(option); + } + + @Override + public IntegerSliderControllerBuilder range(Integer min, Integer max) { + this.min = min; + this.max = max; + return this; + } + + @Override + public IntegerSliderControllerBuilder step(Integer step) { + this.step = step; + return this; + } + + @Override + public IntegerSliderControllerBuilder valueFormatter(Function formatter) { + this.formatter = formatter; + return this; + } + + @Override + public Controller build() { + return new IntegerSliderController(option, min, max, step, formatter); + } +} diff --git a/common/src/main/java/dev/isxander/yacl3/impl/controller/LongFieldControllerBuilderImpl.java b/common/src/main/java/dev/isxander/yacl3/impl/controller/LongFieldControllerBuilderImpl.java new file mode 100644 index 0000000..88cb610 --- /dev/null +++ b/common/src/main/java/dev/isxander/yacl3/impl/controller/LongFieldControllerBuilderImpl.java @@ -0,0 +1,50 @@ +package dev.isxander.yacl3.impl.controller; + +import dev.isxander.yacl3.api.Controller; +import dev.isxander.yacl3.api.Option; +import dev.isxander.yacl3.api.controller.LongFieldControllerBuilder; +import dev.isxander.yacl3.gui.controllers.slider.LongSliderController; +import dev.isxander.yacl3.gui.controllers.string.number.LongFieldController; +import net.minecraft.network.chat.Component; + +import java.util.function.Function; + +public class LongFieldControllerBuilderImpl extends AbstractControllerBuilderImpl implements LongFieldControllerBuilder { + private long min = Long.MIN_VALUE; + private long max = Long.MAX_VALUE; + private Function formatter = LongSliderController.DEFAULT_FORMATTER; + + public LongFieldControllerBuilderImpl(Option option) { + super(option); + } + + @Override + public LongFieldControllerBuilder min(Long min) { + this.min = min; + return this; + } + + @Override + public LongFieldControllerBuilder max(Long max) { + this.max = max; + return this; + } + + @Override + public LongFieldControllerBuilder range(Long min, Long max) { + this.min = min; + this.max = max; + return this; + } + + @Override + public LongFieldControllerBuilder valueFormatter(Function formatter) { + this.formatter = formatter; + return this; + } + + @Override + public Controller build() { + return new LongFieldController(option, min, max, formatter); + } +} diff --git a/common/src/main/java/dev/isxander/yacl3/impl/controller/LongSliderControllerBuilderImpl.java b/common/src/main/java/dev/isxander/yacl3/impl/controller/LongSliderControllerBuilderImpl.java new file mode 100644 index 0000000..2bd932a --- /dev/null +++ b/common/src/main/java/dev/isxander/yacl3/impl/controller/LongSliderControllerBuilderImpl.java @@ -0,0 +1,43 @@ +package dev.isxander.yacl3.impl.controller; + +import dev.isxander.yacl3.api.Controller; +import dev.isxander.yacl3.api.Option; +import dev.isxander.yacl3.api.controller.LongSliderControllerBuilder; +import dev.isxander.yacl3.gui.controllers.slider.LongSliderController; +import net.minecraft.network.chat.Component; + +import java.util.function.Function; + +public class LongSliderControllerBuilderImpl extends AbstractControllerBuilderImpl implements LongSliderControllerBuilder { + private long min, max; + private long step; + private Function formatter = LongSliderController.DEFAULT_FORMATTER; + + public LongSliderControllerBuilderImpl(Option option) { + super(option); + } + + @Override + public LongSliderControllerBuilder range(Long min, Long max) { + this.min = min; + this.max = max; + return this; + } + + @Override + public LongSliderControllerBuilder step(Long step) { + this.step = step; + return this; + } + + @Override + public LongSliderControllerBuilder valueFormatter(Function formatter) { + this.formatter = formatter; + return this; + } + + @Override + public Controller build() { + return new LongSliderController(option, min, max, step, formatter); + } +} diff --git a/common/src/main/java/dev/isxander/yacl3/impl/controller/StringControllerBuilderImpl.java b/common/src/main/java/dev/isxander/yacl3/impl/controller/StringControllerBuilderImpl.java new file mode 100644 index 0000000..a0f51b9 --- /dev/null +++ b/common/src/main/java/dev/isxander/yacl3/impl/controller/StringControllerBuilderImpl.java @@ -0,0 +1,17 @@ +package dev.isxander.yacl3.impl.controller; + +import dev.isxander.yacl3.api.Controller; +import dev.isxander.yacl3.api.Option; +import dev.isxander.yacl3.api.controller.StringControllerBuilder; +import dev.isxander.yacl3.gui.controllers.string.StringController; + +public class StringControllerBuilderImpl extends AbstractControllerBuilderImpl implements StringControllerBuilder { + public StringControllerBuilderImpl(Option option) { + super(option); + } + + @Override + public Controller build() { + return new StringController(option); + } +} diff --git a/common/src/main/java/dev/isxander/yacl3/impl/controller/TickBoxControllerBuilderImpl.java b/common/src/main/java/dev/isxander/yacl3/impl/controller/TickBoxControllerBuilderImpl.java new file mode 100644 index 0000000..3b29719 --- /dev/null +++ b/common/src/main/java/dev/isxander/yacl3/impl/controller/TickBoxControllerBuilderImpl.java @@ -0,0 +1,17 @@ +package dev.isxander.yacl3.impl.controller; + +import dev.isxander.yacl3.api.Controller; +import dev.isxander.yacl3.api.Option; +import dev.isxander.yacl3.api.controller.TickBoxControllerBuilder; +import dev.isxander.yacl3.gui.controllers.TickBoxController; + +public class TickBoxControllerBuilderImpl extends AbstractControllerBuilderImpl implements TickBoxControllerBuilder { + public TickBoxControllerBuilderImpl(Option option) { + super(option); + } + + @Override + public Controller build() { + return new TickBoxController(option); + } +} -- cgit