From d19642e22ea155d39813745afcc9cea14e2c26d8 Mon Sep 17 00:00:00 2001 From: Juuz <6596629+Juuxel@users.noreply.github.com> Date: Sat, 18 Mar 2023 20:10:07 +0200 Subject: Add missing since tags, remove outdated TODO --- src/main/java/io/github/cottonmc/cotton/gui/widget/data/Rect2i.java | 1 + src/main/java/io/github/cottonmc/cotton/gui/widget/focus/Focus.java | 1 + .../java/io/github/cottonmc/cotton/gui/widget/focus/FocusHandler.java | 1 + .../java/io/github/cottonmc/cotton/gui/widget/focus/package-info.java | 2 ++ src/main/java/io/github/cottonmc/cotton/gui/widget/icon/ItemIcon.java | 1 - 5 files changed, 5 insertions(+), 1 deletion(-) (limited to 'src') 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 the key type + * @since 7.0.0 */ public record Focus(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 the focus key type + * @since 7.0.0 */ public interface FocusHandler { /** 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; -- cgit