diff options
Diffstat (limited to 'src/main/java/io')
-rw-r--r-- | src/main/java/io/github/cottonmc/cotton/gui/widget/WToggleButton.java | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/main/java/io/github/cottonmc/cotton/gui/widget/WToggleButton.java b/src/main/java/io/github/cottonmc/cotton/gui/widget/WToggleButton.java index e860a5f..4c75113 100644 --- a/src/main/java/io/github/cottonmc/cotton/gui/widget/WToggleButton.java +++ b/src/main/java/io/github/cottonmc/cotton/gui/widget/WToggleButton.java @@ -21,7 +21,7 @@ public class WToggleButton extends WWidget { protected Identifier onImage; protected Identifier offImage; - protected Text label = null; + @Nullable protected Text label = null; protected boolean isOn = false; @Nullable protected Consumer<Boolean> onToggle = null; @@ -124,11 +124,12 @@ public class WToggleButton extends WWidget { return this; } + @Nullable public Text getLabel() { return label; } - public void setLabel(Text label) { + public void setLabel(@Nullable Text label) { this.label = label; } |