javax.swing.plaf.basic
Class BasicDesktopIconUI

java.lang.Object sample code for java.lang.Object definition code for java.lang.Object 
  extended by javax.swing.plaf.ComponentUI sample code for javax.swing.plaf.ComponentUI definition code for javax.swing.plaf.ComponentUI 
      extended by javax.swing.plaf.DesktopIconUI sample code for javax.swing.plaf.DesktopIconUI definition code for javax.swing.plaf.DesktopIconUI 
          extended by javax.swing.plaf.basic.BasicDesktopIconUI
Direct Known Subclasses:
MetalDesktopIconUI sample code for javax.swing.plaf.metal.MetalDesktopIconUI definition code for javax.swing.plaf.metal.MetalDesktopIconUI

public class BasicDesktopIconUI
extends DesktopIconUI sample code for javax.swing.plaf.DesktopIconUI definition code for javax.swing.plaf.DesktopIconUI

Basic L&F for a minimized window on a desktop.


Nested Class Summary
 class BasicDesktopIconUI.MouseInputHandler sample code for javax.swing.plaf.basic.BasicDesktopIconUI.MouseInputHandler definition code for javax.swing.plaf.basic.BasicDesktopIconUI.MouseInputHandler
          Listens for mouse movements and acts on them.
 
Field Summary
protected  JInternalFrame.JDesktopIcon sample code for javax.swing.JInternalFrame.JDesktopIcon definition code for javax.swing.JInternalFrame.JDesktopIcon desktopIcon sample code for javax.swing.plaf.basic.BasicDesktopIconUI.desktopIcon definition code for javax.swing.plaf.basic.BasicDesktopIconUI.desktopIcon
           
protected  JInternalFrame sample code for javax.swing.JInternalFrame definition code for javax.swing.JInternalFrame frame sample code for javax.swing.plaf.basic.BasicDesktopIconUI.frame definition code for javax.swing.plaf.basic.BasicDesktopIconUI.frame
           
protected  JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent iconPane sample code for javax.swing.plaf.basic.BasicDesktopIconUI.iconPane definition code for javax.swing.plaf.basic.BasicDesktopIconUI.iconPane
          The title pane component used in the desktop icon.
 
Constructor Summary
BasicDesktopIconUI sample code for javax.swing.plaf.basic.BasicDesktopIconUI.BasicDesktopIconUI() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.BasicDesktopIconUI() ()
           
 
Method Summary
protected  MouseInputListener sample code for javax.swing.event.MouseInputListener definition code for javax.swing.event.MouseInputListener createMouseInputListener sample code for javax.swing.plaf.basic.BasicDesktopIconUI.createMouseInputListener() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.createMouseInputListener() ()
           
static ComponentUI sample code for javax.swing.plaf.ComponentUI definition code for javax.swing.plaf.ComponentUI createUI sample code for javax.swing.plaf.basic.BasicDesktopIconUI.createUI(javax.swing.JComponent) definition code for javax.swing.plaf.basic.BasicDesktopIconUI.createUI(javax.swing.JComponent) (JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent  c)
           
 void deiconize sample code for javax.swing.plaf.basic.BasicDesktopIconUI.deiconize() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.deiconize() ()
           
 Insets sample code for java.awt.Insets definition code for java.awt.Insets getInsets sample code for javax.swing.plaf.basic.BasicDesktopIconUI.getInsets(javax.swing.JComponent) definition code for javax.swing.plaf.basic.BasicDesktopIconUI.getInsets(javax.swing.JComponent) (JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent  c)
           
 Dimension sample code for java.awt.Dimension definition code for java.awt.Dimension getMaximumSize sample code for javax.swing.plaf.basic.BasicDesktopIconUI.getMaximumSize(javax.swing.JComponent) definition code for javax.swing.plaf.basic.BasicDesktopIconUI.getMaximumSize(javax.swing.JComponent) (JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent  c)
          Desktop icons can not be resized.
 Dimension sample code for java.awt.Dimension definition code for java.awt.Dimension getMinimumSize sample code for javax.swing.plaf.basic.BasicDesktopIconUI.getMinimumSize(javax.swing.JComponent) definition code for javax.swing.plaf.basic.BasicDesktopIconUI.getMinimumSize(javax.swing.JComponent) (JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent  c)
          Returns the specified component's minimum size appropriate for the look and feel.
 Dimension sample code for java.awt.Dimension definition code for java.awt.Dimension getPreferredSize sample code for javax.swing.plaf.basic.BasicDesktopIconUI.getPreferredSize(javax.swing.JComponent) definition code for javax.swing.plaf.basic.BasicDesktopIconUI.getPreferredSize(javax.swing.JComponent) (JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent  c)
          Returns the specified component's preferred size appropriate for the look and feel.
protected  void installComponents sample code for javax.swing.plaf.basic.BasicDesktopIconUI.installComponents() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.installComponents() ()
           
protected  void installDefaults sample code for javax.swing.plaf.basic.BasicDesktopIconUI.installDefaults() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.installDefaults() ()
           
protected  void installListeners sample code for javax.swing.plaf.basic.BasicDesktopIconUI.installListeners() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.installListeners() ()
           
 void installUI sample code for javax.swing.plaf.basic.BasicDesktopIconUI.installUI(javax.swing.JComponent) definition code for javax.swing.plaf.basic.BasicDesktopIconUI.installUI(javax.swing.JComponent) (JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent  c)
          Configures the specified component appropriate for the look and feel.
protected  void uninstallComponents sample code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallComponents() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallComponents() ()
           
protected  void uninstallDefaults sample code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallDefaults() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallDefaults() ()
           
protected  void uninstallListeners sample code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallListeners() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallListeners() ()
           
 void uninstallUI sample code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallUI(javax.swing.JComponent) definition code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallUI(javax.swing.JComponent) (JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent  c)
          Reverses configuration which was done on the specified component during installUI.
 
Methods inherited from class javax.swing.plaf.ComponentUI sample code for javax.swing.plaf.ComponentUI definition code for javax.swing.plaf.ComponentUI
contains sample code for javax.swing.plaf.ComponentUI.contains(javax.swing.JComponent, int, int) definition code for javax.swing.plaf.ComponentUI.contains(javax.swing.JComponent, int, int) , getAccessibleChild sample code for javax.swing.plaf.ComponentUI.getAccessibleChild(javax.swing.JComponent, int) definition code for javax.swing.plaf.ComponentUI.getAccessibleChild(javax.swing.JComponent, int) , getAccessibleChildrenCount sample code for javax.swing.plaf.ComponentUI.getAccessibleChildrenCount(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.getAccessibleChildrenCount(javax.swing.JComponent) , paint sample code for javax.swing.plaf.ComponentUI.paint(java.awt.Graphics, javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.paint(java.awt.Graphics, javax.swing.JComponent) , update sample code for javax.swing.plaf.ComponentUI.update(java.awt.Graphics, javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.update(java.awt.Graphics, javax.swing.JComponent)
 
Methods inherited from class java.lang.Object sample code for java.lang.Object definition code for java.lang.Object
clone sample code for java.lang.Object.clone() definition code for java.lang.Object.clone() , equals sample code for java.lang.Object.equals(java.lang.Object) definition code for java.lang.Object.equals(java.lang.Object) , finalize sample code for java.lang.Object.finalize() definition code for java.lang.Object.finalize() , getClass sample code for java.lang.Object.getClass() definition code for java.lang.Object.getClass() , hashCode sample code for java.lang.Object.hashCode() definition code for java.lang.Object.hashCode() , notify sample code for java.lang.Object.notify() definition code for java.lang.Object.notify() , notifyAll sample code for java.lang.Object.notifyAll() definition code for java.lang.Object.notifyAll() , toString sample code for java.lang.Object.toString() definition code for java.lang.Object.toString() , wait sample code for java.lang.Object.wait() definition code for java.lang.Object.wait() , wait sample code for java.lang.Object.wait(long) definition code for java.lang.Object.wait(long) , wait sample code for java.lang.Object.wait(long, int) definition code for java.lang.Object.wait(long, int)
 

Field Detail

desktopIcon sample code for javax.swing.plaf.basic.BasicDesktopIconUI.desktopIcon

protected JInternalFrame.JDesktopIcon sample code for javax.swing.JInternalFrame.JDesktopIcon definition code for javax.swing.JInternalFrame.JDesktopIcon  desktopIcon

frame sample code for javax.swing.plaf.basic.BasicDesktopIconUI.frame

protected JInternalFrame sample code for javax.swing.JInternalFrame definition code for javax.swing.JInternalFrame  frame

iconPane sample code for javax.swing.plaf.basic.BasicDesktopIconUI.iconPane

protected JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent  iconPane
The title pane component used in the desktop icon.

Since:
1.5
Constructor Detail

BasicDesktopIconUI sample code for javax.swing.plaf.basic.BasicDesktopIconUI() definition code for javax.swing.plaf.basic.BasicDesktopIconUI()

public BasicDesktopIconUI()
Method Detail

createUI sample code for javax.swing.plaf.basic.BasicDesktopIconUI.createUI(javax.swing.JComponent) definition code for javax.swing.plaf.basic.BasicDesktopIconUI.createUI(javax.swing.JComponent)

public static ComponentUI sample code for javax.swing.plaf.ComponentUI definition code for javax.swing.plaf.ComponentUI  createUI(JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent  c)

installUI sample code for javax.swing.plaf.basic.BasicDesktopIconUI.installUI(javax.swing.JComponent) definition code for javax.swing.plaf.basic.BasicDesktopIconUI.installUI(javax.swing.JComponent)

public void installUI(JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent  c)
Description copied from class: ComponentUI sample code for javax.swing.plaf.ComponentUI.installUI(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.installUI(javax.swing.JComponent)
Configures the specified component appropriate for the look and feel. This method is invoked when the ComponentUI instance is being installed as the UI delegate on the specified component. This method should completely configure the component for the look and feel, including the following:
  1. Install any default property values for color, fonts, borders, icons, opacity, etc. on the component. Whenever possible, property values initialized by the client program should not be overridden.
  2. Install a LayoutManager on the component if necessary.
  3. Create/add any required sub-components to the component.
  4. Create/install event listeners on the component.
  5. Create/install a PropertyChangeListener on the component in order to detect and respond to component property changes appropriately.
  6. Install keyboard UI (mnemonics, traversal, etc.) on the component.
  7. Initialize any appropriate instance data.

Overrides:
installUI sample code for javax.swing.plaf.ComponentUI.installUI(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.installUI(javax.swing.JComponent) in class ComponentUI sample code for javax.swing.plaf.ComponentUI definition code for javax.swing.plaf.ComponentUI
Parameters:
c - the component where this UI delegate is being installed
See Also:
ComponentUI.uninstallUI(javax.swing.JComponent) sample code for javax.swing.plaf.ComponentUI.uninstallUI(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.uninstallUI(javax.swing.JComponent) , JComponent.setUI(javax.swing.plaf.ComponentUI) sample code for javax.swing.JComponent.setUI(javax.swing.plaf.ComponentUI) definition code for javax.swing.JComponent.setUI(javax.swing.plaf.ComponentUI) , JComponent.updateUI() sample code for javax.swing.JComponent.updateUI() definition code for javax.swing.JComponent.updateUI()

uninstallUI sample code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallUI(javax.swing.JComponent) definition code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallUI(javax.swing.JComponent)

public void uninstallUI(JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent  c)
Description copied from class: ComponentUI sample code for javax.swing.plaf.ComponentUI.uninstallUI(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.uninstallUI(javax.swing.JComponent)
Reverses configuration which was done on the specified component during installUI. This method is invoked when this UIComponent instance is being removed as the UI delegate for the specified component. This method should undo the configuration performed in installUI, being careful to leave the JComponent instance in a clean state (no extraneous listeners, look-and-feel-specific property objects, etc.). This should include the following:
  1. Remove any UI-set borders from the component.
  2. Remove any UI-set layout managers on the component.
  3. Remove any UI-added sub-components from the component.
  4. Remove any UI-added event/property listeners from the component.
  5. Remove any UI-installed keyboard UI from the component.
  6. Nullify any allocated instance data objects to allow for GC.

Overrides:
uninstallUI sample code for javax.swing.plaf.ComponentUI.uninstallUI(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.uninstallUI(javax.swing.JComponent) in class ComponentUI sample code for javax.swing.plaf.ComponentUI definition code for javax.swing.plaf.ComponentUI
Parameters:
c - the component from which this UI delegate is being removed; this argument is often ignored, but might be used if the UI object is stateless and shared by multiple components
See Also:
ComponentUI.installUI(javax.swing.JComponent) sample code for javax.swing.plaf.ComponentUI.installUI(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.installUI(javax.swing.JComponent) , JComponent.updateUI() sample code for javax.swing.JComponent.updateUI() definition code for javax.swing.JComponent.updateUI()

installComponents sample code for javax.swing.plaf.basic.BasicDesktopIconUI.installComponents() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.installComponents()

protected void installComponents()

uninstallComponents sample code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallComponents() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallComponents()

protected void uninstallComponents()

installListeners sample code for javax.swing.plaf.basic.BasicDesktopIconUI.installListeners() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.installListeners()

protected void installListeners()

uninstallListeners sample code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallListeners() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallListeners()

protected void uninstallListeners()

installDefaults sample code for javax.swing.plaf.basic.BasicDesktopIconUI.installDefaults() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.installDefaults()

protected void installDefaults()

uninstallDefaults sample code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallDefaults() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.uninstallDefaults()

protected void uninstallDefaults()

createMouseInputListener sample code for javax.swing.plaf.basic.BasicDesktopIconUI.createMouseInputListener() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.createMouseInputListener()

protected MouseInputListener sample code for javax.swing.event.MouseInputListener definition code for javax.swing.event.MouseInputListener  createMouseInputListener()

getPreferredSize sample code for javax.swing.plaf.basic.BasicDesktopIconUI.getPreferredSize(javax.swing.JComponent) definition code for javax.swing.plaf.basic.BasicDesktopIconUI.getPreferredSize(javax.swing.JComponent)

public Dimension sample code for java.awt.Dimension definition code for java.awt.Dimension  getPreferredSize(JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent  c)
Description copied from class: ComponentUI sample code for javax.swing.plaf.ComponentUI.getPreferredSize(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.getPreferredSize(javax.swing.JComponent)
Returns the specified component's preferred size appropriate for the look and feel. If null is returned, the preferred size will be calculated by the component's layout manager instead (this is the preferred approach for any component with a specific layout manager installed). The default implementation of this method returns null.

Overrides:
getPreferredSize sample code for javax.swing.plaf.ComponentUI.getPreferredSize(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.getPreferredSize(javax.swing.JComponent) in class ComponentUI sample code for javax.swing.plaf.ComponentUI definition code for javax.swing.plaf.ComponentUI
Parameters:
c - the component whose preferred size is being queried; this argument is often ignored, but might be used if the UI object is stateless and shared by multiple components
See Also:
JComponent.getPreferredSize() sample code for javax.swing.JComponent.getPreferredSize() definition code for javax.swing.JComponent.getPreferredSize() , LayoutManager.preferredLayoutSize(java.awt.Container) sample code for java.awt.LayoutManager.preferredLayoutSize(java.awt.Container) definition code for java.awt.LayoutManager.preferredLayoutSize(java.awt.Container)

getMinimumSize sample code for javax.swing.plaf.basic.BasicDesktopIconUI.getMinimumSize(javax.swing.JComponent) definition code for javax.swing.plaf.basic.BasicDesktopIconUI.getMinimumSize(javax.swing.JComponent)

public Dimension sample code for java.awt.Dimension definition code for java.awt.Dimension  getMinimumSize(JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent  c)
Description copied from class: ComponentUI sample code for javax.swing.plaf.ComponentUI.getMinimumSize(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.getMinimumSize(javax.swing.JComponent)
Returns the specified component's minimum size appropriate for the look and feel. If null is returned, the minimum size will be calculated by the component's layout manager instead (this is the preferred approach for any component with a specific layout manager installed). The default implementation of this method invokes getPreferredSize and returns that value.

Overrides:
getMinimumSize sample code for javax.swing.plaf.ComponentUI.getMinimumSize(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.getMinimumSize(javax.swing.JComponent) in class ComponentUI sample code for javax.swing.plaf.ComponentUI definition code for javax.swing.plaf.ComponentUI
Parameters:
c - the component whose minimum size is being queried; this argument is often ignored, but might be used if the UI object is stateless and shared by multiple components
Returns:
a Dimension object or null
See Also:
JComponent.getMinimumSize() sample code for javax.swing.JComponent.getMinimumSize() definition code for javax.swing.JComponent.getMinimumSize() , LayoutManager.minimumLayoutSize(java.awt.Container) sample code for java.awt.LayoutManager.minimumLayoutSize(java.awt.Container) definition code for java.awt.LayoutManager.minimumLayoutSize(java.awt.Container) , ComponentUI.getPreferredSize(javax.swing.JComponent) sample code for javax.swing.plaf.ComponentUI.getPreferredSize(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.getPreferredSize(javax.swing.JComponent)

getMaximumSize sample code for javax.swing.plaf.basic.BasicDesktopIconUI.getMaximumSize(javax.swing.JComponent) definition code for javax.swing.plaf.basic.BasicDesktopIconUI.getMaximumSize(javax.swing.JComponent)

public Dimension sample code for java.awt.Dimension definition code for java.awt.Dimension  getMaximumSize(JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent  c)
Desktop icons can not be resized. Therefore, we should always return the minimum size of the desktop icon.

Overrides:
getMaximumSize sample code for javax.swing.plaf.ComponentUI.getMaximumSize(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.getMaximumSize(javax.swing.JComponent) in class ComponentUI sample code for javax.swing.plaf.ComponentUI definition code for javax.swing.plaf.ComponentUI
Parameters:
c - the component whose maximum size is being queried; this argument is often ignored, but might be used if the UI object is stateless and shared by multiple components
Returns:
a Dimension object or null
See Also:
getMinimumSize(javax.swing.JComponent) sample code for javax.swing.plaf.basic.BasicDesktopIconUI.getMinimumSize(javax.swing.JComponent) definition code for javax.swing.plaf.basic.BasicDesktopIconUI.getMinimumSize(javax.swing.JComponent)

getInsets sample code for javax.swing.plaf.basic.BasicDesktopIconUI.getInsets(javax.swing.JComponent) definition code for javax.swing.plaf.basic.BasicDesktopIconUI.getInsets(javax.swing.JComponent)

public Insets sample code for java.awt.Insets definition code for java.awt.Insets  getInsets(JComponent sample code for javax.swing.JComponent definition code for javax.swing.JComponent  c)

deiconize sample code for javax.swing.plaf.basic.BasicDesktopIconUI.deiconize() definition code for javax.swing.plaf.basic.BasicDesktopIconUI.deiconize()

public void deiconize()