Class MinimumFrameSizeComponent

java.lang.Object
  extended by java.awt.event.ComponentAdapter
      extended by MinimumFrameSizeComponent
All Implemented Interfaces:
java.awt.event.ComponentListener, java.util.EventListener

public class MinimumFrameSizeComponent
extends java.awt.event.ComponentAdapter

A component adapter to ensure a component does not get resized below the specified dimensions.


Constructor Summary
MinimumFrameSizeComponent(int minimumWidth, int minimumHeight)
          Constructs a MinimumFrameSizeComponent that restricts a component to the minimumWidth and minimumHeight in pixels.
 
Method Summary
 void componentResized(java.awt.event.ComponentEvent e)
          Called when a component is resized, and prevents the component from becoming smaller than minimumWidth and minimumHeight.
 
Methods inherited from class java.awt.event.ComponentAdapter
componentHidden, componentMoved, componentShown
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MinimumFrameSizeComponent

public MinimumFrameSizeComponent(int minimumWidth,
                                 int minimumHeight)
Constructs a MinimumFrameSizeComponent that restricts a component to the minimumWidth and minimumHeight in pixels.

Parameters:
minimumWidth - The minimum width in pixels.
minimumHeight - The minimum height in pixels.
Method Detail

componentResized

public void componentResized(java.awt.event.ComponentEvent e)
Called when a component is resized, and prevents the component from becoming smaller than minimumWidth and minimumHeight.

Specified by:
componentResized in interface java.awt.event.ComponentListener
Overrides:
componentResized in class java.awt.event.ComponentAdapter