|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--java.awt.Component
|
+--java.awt.Container
|
+--javax.swing.JComponent
|
+--javax.swing.JScrollPane
|
+--org.jscroll.widgets.DesktopScrollPane
This class provides the scrollpane that contains the virtual desktop.
| Field Summary |
| Fields inherited from class javax.swing.JScrollPane |
columnHeader, horizontalScrollBar, horizontalScrollBarPolicy, lowerLeft, lowerRight, rowHeader, upperLeft, upperRight, verticalScrollBar, verticalScrollBarPolicy, viewport |
| Fields inherited from class javax.swing.JComponent |
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
DesktopScrollPane(DesktopMediator desktopMediator)
creates the DesktopScrollPane object |
|
| Method Summary | |
void |
add(DesktopListener dListener,
JInternalFrame f,
int x,
int y)
adds an internal frame to the virtual desktop |
JScrollInternalFrame |
add(DesktopListener dListener,
String title,
ImageIcon icon,
JPanel frameContents,
boolean isClosable,
int x,
int y)
creates a JScrollInternalFrame and adds it to the virtual desktop |
Point |
cascadeInternalFrame(JInternalFrame f)
propogates cascadeInternalFrame to FramePositioning |
void |
cascadeInternalFrames()
propogates cascadeInternalFrames to FramePositioning |
void |
centerView(JScrollInternalFrame f)
centers the viewport of the virtual desktop around the provided internal frame |
void |
closeSelectedFrame()
closes the internal frame currently selected upon the virtual desktop |
void |
flagContentsChanged(JInternalFrame f)
flags the specified internal frame as "contents changed." Used to notify the user when the contents of an inactive internal frame have changed. |
JInternalFrame[] |
getAllFrames()
returns all internal frames placed upon the virtual desktop |
boolean |
getAutoTile()
propogates getAutoTile to FramePositioning |
Dimension |
getDesktopSize()
returns the preferred size of the virtual desktop |
int |
getNumberOfFrames()
returns the number of internal frames upon the virtual desktop |
JInternalFrame |
getSelectedFrame()
returns the internal frame currently selected upon the virtual desktop |
void |
removeAssociatedComponents(JScrollInternalFrame f)
propogates removeAssociatedComponents to DesktopMediator |
void |
resizeDesktop()
resizes the virtual desktop based upon the locations of its internal frames. |
void |
selectNextFrame()
selects the next available frame upon the virtual desktop |
void |
setAutoTile(boolean autoTile)
propogates setAutoTile to FramePositioning |
void |
setDesktopSize(Dimension dim)
sets the preferred size of the virtual desktop |
void |
setSelectedFrame(JInternalFrame f)
selects the specified internal frame upon the virtual desktop |
void |
tileInternalFrames()
propogates tileInternalFrames to FramePositioning |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public DesktopScrollPane(DesktopMediator desktopMediator)
desktopMediator - a reference to the DesktopMediator object| Method Detail |
public JScrollInternalFrame add(DesktopListener dListener,
String title,
ImageIcon icon,
JPanel frameContents,
boolean isClosable,
int x,
int y)
dListener - a reference to the DesktopListenertitle - the title displayed in the title bar of the internal frameicon - the icon displayed in the title bar of the internal frameframeContents - the contents of the internal frameisClosable - boolean indicating whether internal frame
is closablex - x coordinates of internal frame within the scrollable desktop.
-1 indicates the virtual desktop is to determine the positiony - y coordinates of internal frame within the scrollable desktop
-1 indicates the virtual desktop is to determine the position
public void add(DesktopListener dListener,
JInternalFrame f,
int x,
int y)
dListener - a reference to the DesktopListenerf - the internal frame to addx - x coordinates of internal frame within the scrollable desktop.
-1 indicates the virtual desktop is to determine the positiony - y coordinates of internal frame within the scrollable desktop
-1 indicates the virtual desktop is to determine the positionpublic JInternalFrame[] getAllFrames()
public JInternalFrame getSelectedFrame()
public void closeSelectedFrame()
public void setSelectedFrame(JInternalFrame f)
f - the internal frame to selectpublic void flagContentsChanged(JInternalFrame f)
f - the internal frame to flag as "contents changed"public void selectNextFrame()
public int getNumberOfFrames()
int representing the number of internal framespublic void setDesktopSize(Dimension dim)
dim - a Dimension object representing the desired preferred sizepublic Dimension getDesktopSize()
public void setAutoTile(boolean autoTile)
autoTile - boolean representing autoTile mode.
If true, then all new frames are tiled automatically.
If false, then all new frames are cascaded automatically.public boolean getAutoTile()
boolean representing current autoTile modepublic Point cascadeInternalFrame(JInternalFrame f)
f - the internal frame to cascade
public void cascadeInternalFrames()
public void tileInternalFrames()
public void centerView(JScrollInternalFrame f)
f - the internal frame to center the viewport aboutpublic void resizeDesktop()
public void removeAssociatedComponents(JScrollInternalFrame f)
f - the internal frame whose associated components are
to be removed
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||