aboutsummaryrefslogtreecommitdiff
path: root/src/main/java
diff options
context:
space:
mode:
authorJuuz <6596629+Juuxel@users.noreply.github.com>2023-03-18 20:10:07 +0200
committerJuuz <6596629+Juuxel@users.noreply.github.com>2023-03-18 20:10:07 +0200
commitd19642e22ea155d39813745afcc9cea14e2c26d8 (patch)
treef5c529f46169cbae40d0b7b895160478a025a90a /src/main/java
parent6835bb564b28075dcf05605560827d92994f44d9 (diff)
downloadLibGui-d19642e22ea155d39813745afcc9cea14e2c26d8.tar.gz
LibGui-d19642e22ea155d39813745afcc9cea14e2c26d8.tar.bz2
LibGui-d19642e22ea155d39813745afcc9cea14e2c26d8.zip
Add missing since tags, remove outdated TODO
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/io/github/cottonmc/cotton/gui/widget/data/Rect2i.java1
-rw-r--r--src/main/java/io/github/cottonmc/cotton/gui/widget/focus/Focus.java1
-rw-r--r--src/main/java/io/github/cottonmc/cotton/gui/widget/focus/FocusHandler.java1
-rw-r--r--src/main/java/io/github/cottonmc/cotton/gui/widget/focus/package-info.java2
-rw-r--r--src/main/java/io/github/cottonmc/cotton/gui/widget/icon/ItemIcon.java1
5 files changed, 5 insertions, 1 deletions
diff --git a/src/main/java/io/github/cottonmc/cotton/gui/widget/data/Rect2i.java b/src/main/java/io/github/cottonmc/cotton/gui/widget/data/Rect2i.java
index b8e81a3..f5557ac 100644
--- a/src/main/java/io/github/cottonmc/cotton/gui/widget/data/Rect2i.java
+++ b/src/main/java/io/github/cottonmc/cotton/gui/widget/data/Rect2i.java
@@ -8,6 +8,7 @@ package io.github.cottonmc.cotton.gui.widget.data;
* @param y the Y coordinate
* @param width the horizontal size
* @param height the vertical size
+ * @since 7.0.0
*/
public record Rect2i(int x, int y, int width, int height) {
}
diff --git a/src/main/java/io/github/cottonmc/cotton/gui/widget/focus/Focus.java b/src/main/java/io/github/cottonmc/cotton/gui/widget/focus/Focus.java
index b0b3ab3..f704f42 100644
--- a/src/main/java/io/github/cottonmc/cotton/gui/widget/focus/Focus.java
+++ b/src/main/java/io/github/cottonmc/cotton/gui/widget/focus/Focus.java
@@ -13,6 +13,7 @@ import org.jetbrains.annotations.Nullable;
* @param key the key
* @param area the focusable area in widget space
* @param <K> the key type
+ * @since 7.0.0
*/
public record Focus<K>(K key, Rect2i area) {
/**
diff --git a/src/main/java/io/github/cottonmc/cotton/gui/widget/focus/FocusHandler.java b/src/main/java/io/github/cottonmc/cotton/gui/widget/focus/FocusHandler.java
index f7e5e0d..f3b569e 100644
--- a/src/main/java/io/github/cottonmc/cotton/gui/widget/focus/FocusHandler.java
+++ b/src/main/java/io/github/cottonmc/cotton/gui/widget/focus/FocusHandler.java
@@ -10,6 +10,7 @@ import java.util.stream.Stream;
* Each instance should be specific to one widget.
*
* @param <K> the focus key type
+ * @since 7.0.0
*/
public interface FocusHandler<K> {
/**
diff --git a/src/main/java/io/github/cottonmc/cotton/gui/widget/focus/package-info.java b/src/main/java/io/github/cottonmc/cotton/gui/widget/focus/package-info.java
index dc2c958..a2d48ec 100644
--- a/src/main/java/io/github/cottonmc/cotton/gui/widget/focus/package-info.java
+++ b/src/main/java/io/github/cottonmc/cotton/gui/widget/focus/package-info.java
@@ -1,4 +1,6 @@
/**
* The widget focus API.
+ *
+ * @since 7.0.0
*/
package io.github.cottonmc.cotton.gui.widget.focus;
diff --git a/src/main/java/io/github/cottonmc/cotton/gui/widget/icon/ItemIcon.java b/src/main/java/io/github/cottonmc/cotton/gui/widget/icon/ItemIcon.java
index af90b79..f979b44 100644
--- a/src/main/java/io/github/cottonmc/cotton/gui/widget/icon/ItemIcon.java
+++ b/src/main/java/io/github/cottonmc/cotton/gui/widget/icon/ItemIcon.java
@@ -42,7 +42,6 @@ public class ItemIcon implements Icon {
@Environment(EnvType.CLIENT)
@Override
public void paint(MatrixStack matrices, int x, int y, int size) {
- // TODO: Make this not ignore the actual matrices
MinecraftClient client = MinecraftClient.getInstance();
ItemRenderer renderer = client.getItemRenderer();
float scale = size != 16 ? ((float) size / 16f) : 1f;