aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main/java/io/github/cottonmc/cotton/gui/widget/WListPanel.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/main/java/io/github/cottonmc/cotton/gui/widget/WListPanel.java b/src/main/java/io/github/cottonmc/cotton/gui/widget/WListPanel.java
index 9416f95..876d43a 100644
--- a/src/main/java/io/github/cottonmc/cotton/gui/widget/WListPanel.java
+++ b/src/main/java/io/github/cottonmc/cotton/gui/widget/WListPanel.java
@@ -54,6 +54,13 @@ public class WListPanel<D, W extends WWidget> extends WClippedPanel {
protected WScrollBar scrollBar = new WScrollBar(Axis.VERTICAL);
private int lastScroll = -1;
+ /**
+ * Constructs a list panel.
+ *
+ * @param data the list data
+ * @param supplier the widget supplier that creates unconfigured widgets
+ * @param configurator the widget configurator that configures widgets to display the passed data
+ */
public WListPanel(List<D> data, Supplier<W> supplier, BiConsumer<D, W> configurator) {
this.data = data;
this.supplier = supplier;