question: public void maximiseComponent ( Component component ) { if ( component == null ) { throw new IllegalArgumentException ( "Parameter component must not be null." ) ; } if ( maximisedComponent != null ) { return ; } maximisedComponent = component ; parentMaximisedComponent = component . getParent ( ) ; containerChild = container . getComponent ( 0 ) ; parentMaximisedComponent . remove ( component ) ; container . remove ( containerChild ) ; container . add ( component ) ; container . validate ( ) ; }
target:  Maximises the given component, to occupy the whole container. <p> The maximisation is done by adding the component directly to the container. If another component is already maximised it does nothing.