|
|
Summary
The JFC provides the JDesktopPane and JInternalFrame classes that work together to provide a framework for building multiple document interface type user interfaces. The JInternalFrame classs API is very similar to that of the JFrame class. The JFrame class provides a top-level window, while the JInternalFrame class provides a frame that can be added to other components. Typical use of the internal frames is for it to be added to a JDesktopPane instance. The JDesktopPane class extends the JLayeredPane class. When an internal frame is added to a desktop pane, it functions as a frame that can be independently sized, moved, iconified, and maximized from other internal frames contained in the desktop pane. The complete reference of the JInternalFrame class and the panes it creates were not presented, as they are the same as the JFrame class presented in Chapter 8. Once the JFrame class and its use is understood, the JInternalFrame class is almost completely understood as well.
Sample applications were presented that placed a desktop pane into the content pane of a JFrame instance. Multiple internal frames were added to the desktop pane. These applications demonstrated the cooperative nature of the JDesktopPane and JInternalFrame classes. These two classes are typically used together.
|