X-Git-Url: http://git.nikiroo.be/?a=blobdiff_plain;f=src%2Fjexer%2FTStatusBar.java;fp=src%2Fjexer%2FTStatusBar.java;h=98565d0f8c8c7d50c29ea86218156dbaa991049b;hb=5218e73c343be793d6e7833744565dfbc0f08c31;hp=72a0ec6662163740385f887ecd701fcf5ae4c73f;hpb=5d26b50423486b1e680e3adfc0054f6fd0bbcefe;p=fanfix.git diff --git a/src/jexer/TStatusBar.java b/src/jexer/TStatusBar.java index 72a0ec6..98565d0 100644 --- a/src/jexer/TStatusBar.java +++ b/src/jexer/TStatusBar.java @@ -125,24 +125,26 @@ public class TStatusBar extends TWidget { /** * Public constructor. * - * @param parent parent widget + * @param window the window associated with this status bar * @param text text for the bar on the bottom row */ - public TStatusBar(final TWidget parent, final String text) { + public TStatusBar(final TWindow window, final String text) { - // Set parent and window - super(parent, false, 0, 0, text.length(), 1); + // TStatusBar is a parentless widget, because TApplication handles + // its drawing and event routing directly. + super(null, false, 0, 0, text.length(), 1); this.text = text; + setWindow(window); } /** * Public constructor. * - * @param parent parent widget + * @param window the window associated with this status bar */ - public TStatusBar(final TWidget parent) { - this(parent, ""); + public TStatusBar(final TWindow window) { + this(window, ""); } // ------------------------------------------------------------------------