Methods Summary |
---|
public javax.accessibility.AccessibleContext | getAccessibleContext()Gets the AccessibleContext associated with this
JDesktopPane . For desktop panes, the
AccessibleContext takes the form of an
AccessibleJDesktopPane .
A new AccessibleJDesktopPane instance is created if necessary.
if (accessibleContext == null) {
accessibleContext = new AccessibleJDesktopPane();
}
return accessibleContext;
|
public javax.swing.JInternalFrame[] | getAllFrames()Returns all JInternalFrames currently displayed in the
desktop. Returns iconified frames as well as expanded frames.
int i, count;
JInternalFrame[] results;
Vector vResults = new Vector(10);
Object next, tmp;
count = getComponentCount();
for(i = 0; i < count; i++) {
next = getComponent(i);
if(next instanceof JInternalFrame)
vResults.addElement(next);
else if(next instanceof JInternalFrame.JDesktopIcon) {
tmp = ((JInternalFrame.JDesktopIcon)next).getInternalFrame();
if(tmp != null)
vResults.addElement(tmp);
}
}
results = new JInternalFrame[vResults.size()];
vResults.copyInto(results);
return results;
|
public javax.swing.JInternalFrame[] | getAllFramesInLayer(int layer)Returns all JInternalFrames currently displayed in the
specified layer of the desktop. Returns iconified frames as well
expanded frames.
int i, count;
JInternalFrame[] results;
Vector vResults = new Vector(10);
Object next, tmp;
count = getComponentCount();
for(i = 0; i < count; i++) {
next = getComponent(i);
if(next instanceof JInternalFrame) {
if(((JInternalFrame)next).getLayer() == layer)
vResults.addElement(next);
} else if(next instanceof JInternalFrame.JDesktopIcon) {
tmp = ((JInternalFrame.JDesktopIcon)next).getInternalFrame();
if(tmp != null && ((JInternalFrame)tmp).getLayer() == layer)
vResults.addElement(tmp);
}
}
results = new JInternalFrame[vResults.size()];
vResults.copyInto(results);
return results;
|
public javax.swing.DesktopManager | getDesktopManager()Returns the DesktopManger that handles
desktop-specific UI actions.
return desktopManager;
|
public int | getDragMode()Gets the current "dragging style" used by the desktop pane.
return dragMode;
|
public javax.swing.JInternalFrame | getSelectedFrame()Returns the currently active JInternalFrame
in this JDesktopPane , or null
if no JInternalFrame is currently active.
return selectedFrame;
|
public javax.swing.plaf.DesktopPaneUI | getUI()Returns the L&F object that renders this component.
return (DesktopPaneUI)ui;
|
public java.lang.String | getUIClassID()Returns the name of the L&F class that renders this component.
return uiClassID;
|
public boolean | isOpaque()Returns true to indicate that this component paints every pixel
in its range. (In other words, it does not have a transparent
background or foreground.)
return true;
|
protected java.lang.String | paramString()Returns a string representation of this JDesktopPane .
This method is intended to be used only for debugging purposes, and the
content and format of the returned string may vary between
implementations. The returned string may be empty but may not
be null .
String desktopManagerString = (desktopManager != null ?
desktopManager.toString() : "");
return super.paramString() +
",desktopManager=" + desktopManagerString;
|
public void | setDesktopManager(javax.swing.DesktopManager d)Sets the DesktopManger that will handle
desktop-specific UI actions.
DesktopManager oldValue = desktopManager;
desktopManager = d;
firePropertyChange("desktopManager", oldValue, desktopManager);
|
public void | setDragMode(int dragMode)Sets the "dragging style" used by the desktop pane.
You may want to change to one mode or another for
performance or aesthetic reasons.
int oldDragMode = this.dragMode;
this.dragMode = dragMode;
firePropertyChange("dragMode", oldDragMode, this.dragMode);
dragModeSet = true;
|
public void | setSelectedFrame(javax.swing.JInternalFrame f)Sets the currently active JInternalFrame
in this JDesktopPane .
selectedFrame = f;
|
public void | setUI(javax.swing.plaf.DesktopPaneUI ui)Sets the L&F object that renders this component.
super.setUI(ui);
|
void | setUIProperty(java.lang.String propertyName, java.lang.Object value)
if (propertyName == "dragMode") {
if (!dragModeSet) {
setDragMode(((Integer)value).intValue());
dragModeSet = false;
}
} else {
super.setUIProperty(propertyName, value);
}
|
public void | updateUI()Notification from the UIManager that the L&F has changed.
Replaces the current UI object with the latest version from the
UIManager .
setUI((DesktopPaneUI)UIManager.getUI(this));
|
private void | writeObject(java.io.ObjectOutputStream s)See readObject() and writeObject() in JComponent for more
information about serialization in Swing.
s.defaultWriteObject();
if (getUIClassID().equals(uiClassID)) {
byte count = JComponent.getWriteObjCounter(this);
JComponent.setWriteObjCounter(this, --count);
if (count == 0 && ui != null) {
ui.installUI(this);
}
}
|