FileDocCategorySizeDatePackage
MoreInfoPanel.javaAPI DocExample2968Mon Jan 09 11:01:58 GMT 2006None

MoreInfoPanel

public class MoreInfoPanel extends JPanel

Fields Summary
public Component
topComponent
protected SpinWidget
spinWidget
public Component
bottomComponent
public static final int
SPIN_WIDGET_HEIGHT
Constructors Summary
public MoreInfoPanel(Component tc, Component mic)


          
        topComponent = tc;
        spinWidget = new SpinWidget();
        bottomComponent = mic;
        doMyLayout();
    
Methods Summary
protected voiddoMyLayout()

        setLayout (new BoxLayout (this, BoxLayout.Y_AXIS));
        add (topComponent);
        add (spinWidget);
        add (bottomComponent);
        resetBottomVisibility();
    
public booleanisBottomShowing()

        return spinWidget.isOpen();
    
protected voidresetBottomVisibility()

        if ((bottomComponent == null) ||
            (spinWidget == null))
            return;
        bottomComponent.setVisible (spinWidget.isOpen());
        revalidate();
        if (isShowing()) {
            Container ancestor = getTopLevelAncestor();
            if ((ancestor != null) && (ancestor instanceof Window))
                ((Window) ancestor).pack();
            repaint();
        }
    
public voidshowBottom(boolean b)

        spinWidget.setOpen (b);