Class DockingDesktopManager
java.lang.Object
javax.swing.DefaultDesktopManager
com.inductiveautomation.factorypmi.application.DockingDesktopManager
- All Implemented Interfaces:
Serializable,DesktopManager
The scrolling portion of this class borrowed from JavaWorld See
http://www.javaworld.com/javaworld/jw-05-2001/jw-0525-mdi.html
- See Also:
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidvoidbeginResizingFrame(JComponent f, int direction) voidcenterFrame(JInternalFrame frame) voidvoiddragFrame(JComponent f, int newX, int newY) voidvoidvoidThis function verifies the layout of the docked windows, by checking to see if they are in the correct position, and moving/resizing them if necessary.voidvoidRestores the frame back to its size and position prior to amaximizeFramecall.voidEvaluates what the size of the desktop pane should be given the currently opened windows, and sets it to that size.voidresizeFrame(JComponent f, int newX, int newY, int newWidth, int newHeight) voidsetBoundsForFrame(JComponent f, int newX, int newY, int newWidth, int newHeight) Sets the size for the frame, and calls f.revalidate() if the size changed.Methods inherited from class javax.swing.DefaultDesktopManager
deactivateFrame, deiconifyFrame, getBoundsForIconOf, getPreviousBounds, iconifyFrame, openFrame, removeIconFor, setPreviousBounds, setWasIcon, wasIcon
-
Constructor Details
-
DockingDesktopManager
-
-
Method Details
-
endResizingFrame
- Specified by:
endResizingFramein interfaceDesktopManager- Overrides:
endResizingFramein classDefaultDesktopManager
-
endDraggingFrame
- Specified by:
endDraggingFramein interfaceDesktopManager- Overrides:
endDraggingFramein classDefaultDesktopManager
-
centerFrame
-
layoutDocks
public void layoutDocks()This function verifies the layout of the docked windows, by checking to see if they are in the correct position, and moving/resizing them if necessary.It first lays out the EAST and WEST docked windows, if any, then it lays out the NORTH and SOUTH docked windows in the resulting width. Finally, maximized windows are laid-out.
-
resizeDesktop
public void resizeDesktop()Evaluates what the size of the desktop pane should be given the currently opened windows, and sets it to that size. -
resizeFrame
- Specified by:
resizeFramein interfaceDesktopManager- Overrides:
resizeFramein classDefaultDesktopManager
-
setBoundsForFrame
Sets the size for the frame, and calls f.revalidate() if the size changed.- Specified by:
setBoundsForFramein interfaceDesktopManager- Overrides:
setBoundsForFramein classDefaultDesktopManager
-
dragFrame
- Specified by:
dragFramein interfaceDesktopManager- Overrides:
dragFramein classDefaultDesktopManager
-
beginDraggingFrame
- Specified by:
beginDraggingFramein interfaceDesktopManager- Overrides:
beginDraggingFramein classDefaultDesktopManager
-
beginResizingFrame
- Specified by:
beginResizingFramein interfaceDesktopManager- Overrides:
beginResizingFramein classDefaultDesktopManager
-
closeFrame
- Specified by:
closeFramein interfaceDesktopManager- Overrides:
closeFramein classDefaultDesktopManager
-
minimizeFrame
Restores the frame back to its size and position prior to amaximizeFramecall.- Specified by:
minimizeFramein interfaceDesktopManager- Overrides:
minimizeFramein classDefaultDesktopManager- Parameters:
f- theJInternalFrameto be restored
-
maximizeFrame
- Specified by:
maximizeFramein interfaceDesktopManager- Overrides:
maximizeFramein classDefaultDesktopManager
-
activateFrame
- Specified by:
activateFramein interfaceDesktopManager- Overrides:
activateFramein classDefaultDesktopManager
-