Java AWT | WindowStateListener
WindowStateListener is a part of java.awt.event package. It is an interface to handle window state events. This interface returns an event when the frame or window associated with it is iconified or maximized.
Abstract function of the class:
- windowStateChanged(WindowEvent e) : invoked when a state of the window is changed.
Below programs illustrate the WindowStateListener:
- Java Program to handle window events
- Java Program to handle window events and identify them:
Note : The following program will not run in an online compiler please use an offline IDE