aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/cc/polyfrost/oneconfig/gui/elements/BasicElement.java
diff options
context:
space:
mode:
authorDeDiamondPro <67508414+DeDiamondPro@users.noreply.github.com>2022-06-01 18:41:55 +0200
committerDeDiamondPro <67508414+DeDiamondPro@users.noreply.github.com>2022-06-01 18:41:55 +0200
commitb722c1eff0bda4de2c15d451423367cf2be2f15a (patch)
tree3b87f41c52b144cd101fb40036ad1a3a22618eaf /src/main/java/cc/polyfrost/oneconfig/gui/elements/BasicElement.java
parentb72b3dca39631a995b422e0b3495e8d3618e91d8 (diff)
parente48cd4479f832cdd341ab0a289d1b4a88ab21a3c (diff)
downloadOneConfig-b722c1eff0bda4de2c15d451423367cf2be2f15a.tar.gz
OneConfig-b722c1eff0bda4de2c15d451423367cf2be2f15a.tar.bz2
OneConfig-b722c1eff0bda4de2c15d451423367cf2be2f15a.zip
merge
Diffstat (limited to 'src/main/java/cc/polyfrost/oneconfig/gui/elements/BasicElement.java')
-rw-r--r--src/main/java/cc/polyfrost/oneconfig/gui/elements/BasicElement.java16
1 files changed, 9 insertions, 7 deletions
diff --git a/src/main/java/cc/polyfrost/oneconfig/gui/elements/BasicElement.java b/src/main/java/cc/polyfrost/oneconfig/gui/elements/BasicElement.java
index 8b86827..93e2c07 100644
--- a/src/main/java/cc/polyfrost/oneconfig/gui/elements/BasicElement.java
+++ b/src/main/java/cc/polyfrost/oneconfig/gui/elements/BasicElement.java
@@ -1,27 +1,29 @@
package cc.polyfrost.oneconfig.gui.elements;
import cc.polyfrost.oneconfig.lwjgl.RenderManager;
-import cc.polyfrost.oneconfig.utils.ColorUtils;
+import cc.polyfrost.oneconfig.utils.color.ColorPalette;
+import cc.polyfrost.oneconfig.utils.color.ColorUtils;
import cc.polyfrost.oneconfig.utils.InputUtils;
+import org.jetbrains.annotations.NotNull;
public class BasicElement {
protected int width, height;
- protected int colorPalette;
+ protected ColorPalette colorPalette;
protected int hitBoxX, hitBoxY;
protected boolean hoverFx;
protected boolean hovered = false;
protected boolean clicked = false;
protected boolean toggled = false;
protected boolean disabled = false;
- protected int currentColor;
+ public int currentColor;
protected final float radius;
private boolean block = false;
- public BasicElement(int width, int height, int colorPalette, boolean hoverFx) {
+ public BasicElement(int width, int height, @NotNull ColorPalette colorPalette, boolean hoverFx) {
this(width, height, colorPalette, hoverFx, 12f);
}
- public BasicElement(int width, int height, int colorPalette, boolean hoverFx, float radius) {
+ public BasicElement(int width, int height, @NotNull ColorPalette colorPalette, boolean hoverFx, float radius) {
this.height = height;
this.width = width;
this.colorPalette = colorPalette;
@@ -30,7 +32,7 @@ public class BasicElement {
}
public BasicElement(int width, int height, boolean hoverFx) {
- this(width, height, ColorUtils.TRANSPARENT, hoverFx, 12f);
+ this(width, height, ColorPalette.TRANSPARENT, hoverFx, 12f);
}
@@ -80,7 +82,7 @@ public class BasicElement {
this.height = height;
}
- public void setColorPalette(int colorPalette) {
+ public void setColorPalette(ColorPalette colorPalette) {
this.colorPalette = colorPalette;
}