From: Niki Roo Date: Sat, 18 Apr 2020 15:39:16 +0000 (+0200) Subject: Progress: new convenience constructor X-Git-Url: https://git.nikiroo.be/?a=commitdiff_plain;h=a9cb37ec7ba82c575dc56b3bbbad61df73c938a1;p=nikiroo-utils.git Progress: new convenience constructor --- diff --git a/ui/ProgressBar.java b/ui/ProgressBar.java index 219cde9..11e1e6c 100644 --- a/ui/ProgressBar.java +++ b/ui/ProgressBar.java @@ -35,6 +35,11 @@ public class ProgressBar extends JPanel { actionListeners = new ArrayList(); updateListeners = new ArrayList(); } + + public ProgressBar(Progress pg) { + this(); + setProgress(pg); + } public void setProgress(final Progress pg) { this.pg = pg;