code: private void maximize()
      {
          if (timer != null)
          {
              timer.stop();
              timer = null;
          }
          
          final int targetHeight = getSuperPreferredHeight();
          double steps = (double)durationMS / delayMS;
          double delta = targetHeight - currentHeight;
          final int stepSize = (int)Math.ceil(delta / steps);
          currentHeight = getHeight();
          
          //System.out.println("steps " + steps);
          //System.out.println("currentHeight " + currentHeight);
          //System.out.println("delta " + delta);
          //System.out.println("stepSize " + stepSize);
          
          timer = new Timer(delayMS, new ActionListener()
          {
              @Override
              public void actionPerformed(ActionEvent e)
              {
                  minimized = false;
                  currentHeight += stepSize;
                  currentHeight = Math.min(currentHeight, targetHeight);
                  if (currentHeight >= targetHeight)
                  {
                      currentHeight = Integer.MAX_VALUE;
                      timer.stop();
                      timer = null;
                  }
                  revalidate();
              }
          });
          timer.setInitialDelay(0);
          timer.start();
      }
docs: Performs the maximization process