APIdia Launch Partner
Top Description Inners Fields Constructors Methods
javax.swing.plaf.metal

public Class MetalFileChooserUI

extends BasicFileChooserUI
Class Inheritance
Imports
javax.swing.*, javax.swing.border.EmptyBorder, javax.swing.filechooser.*, javax.swing.event.*, javax.swing.plaf.*, javax.swing.plaf.basic.*, java.awt.*, java.awt.event.*, java.beans.*, java.io.File, .FileNotFoundException, .IOException, java.util.*, javax.accessibility.*, sun.awt.shell.ShellFolder, sun.swing.*

Metal L&F implementation of a FileChooser.
Author
Jeff Dinkins

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static class
private static class
MetalFileChooserUI.ButtonAreaLayout

ButtonAreaLayout behaves in a similar manner to FlowLayout.

protected class
MetalFileChooserUI.DirectoryComboBoxAction

Acts when DirectoryComboBox has changed the selected item.

protected class
MetalFileChooserUI.DirectoryComboBoxModel

Data model for a type-face selection combo-box.

pack-priv class
protected class
MetalFileChooserUI.FileRenderer

Deprecated since 9. As of JDK version 9. Obsolete class.
Obsolete class, not used in this version.
protected class
MetalFileChooserUI.FilterComboBoxModel

Data model for a type-face selection combo-box.

public class
MetalFileChooserUI.FilterComboBoxRenderer

Render different type sizes and styles.

pack-priv static class
private class
protected class
MetalFileChooserUI.SingleClickListener

Deprecated since 9. As of JDK version 9. Obsolete class.
Obsolete class, not used in this version.

Field Summary

Modifier and TypeField and Description
private JButton
private JPanel
private JPanel
private JButton
private JToggleButton
private String
private String
private JComboBox<Object>
private Action
private MetalFileChooserUI.DirectoryComboBoxModel
private MetalFileChooserUI.AlignedLabel
private int
private String
private JTextField
private FilePane
private int
private String
private JComboBox<?>
private MetalFileChooserUI.FilterComboBoxModel
private int
private String
private String
private String
private static final Dimension
private static final Dimension
private static int
private static Dimension
private static int
private JToggleButton
private String
private String
private JLabel
private int
private String
private static int
private static int
private String
private String
private static int
private static Dimension
private static int
private String
private static final Insets
pack-priv static final int
private String
private String
private static final Dimension
Inherited from javax.swing.plaf.basic.BasicFileChooserUI:
cancelButtonMnemoniccancelButtonTextcancelButtonToolTipTextcomputerIcondetailsViewIcondirectoryIcondirectoryOpenButtonMnemonicdirectoryOpenButtonTextdirectoryOpenButtonToolTipTextfileIconfloppyDriveIconhardDriveIconhelpButtonMnemonichelpButtonTexthelpButtonToolTipTexthomeFolderIconlistViewIconnewFolderIconopenButtonMnemonicopenButtonTextopenButtonToolTipTextsaveButtonMnemonicsaveButtonTextsaveButtonToolTipTextupdateButtonMnemonicupdateButtonTextupdateButtonToolTipTextupFolderIconviewMenuIcon

Constructor Summary

AccessConstructor and Description
public
MetalFileChooserUI(JFileChooser
a JFileChooser
filechooser
)

Constructs a new instance of MetalFileChooserUI.

Method Summary

Modifier and TypeMethod and Description
protected void
addControlButtons()

Adds control buttons to bottom panel.

protected ActionMap

Returns:

an instance of ActionMap
createActionMap
()

Hides javax.swing.plaf.basic.BasicFileChooserUI.createActionMap.

Constructs an instance of ActionMap.

protected JPanel

Returns:

the details view
createDetailsView
(JFileChooser
a JFileChooser
fc
)

Constructs a details view.

protected MetalFileChooserUI.DirectoryComboBoxModel

Returns:

a new instance of DataModel for DirectoryComboBox
createDirectoryComboBoxModel
(JFileChooser
a JFileChooser
fc
)

Constructs a new instance of DataModel for DirectoryComboBox.

private DefaultListCellRenderer

Returns:

a new instance of DirectoryComboBoxRenderer
createDirectoryComboBoxRenderer
(JFileChooser
a JFileChooser
fc
)

Constructs a new instance of DirectoryComboBoxRenderer.

protected MetalFileChooserUI.FilterComboBoxModel

Returns:

a DataModel for types ComboBox
createFilterComboBoxModel
()

Constructs a DataModel for types ComboBox.

protected MetalFileChooserUI.FilterComboBoxRenderer

Returns:

a Renderer for types ComboBox
createFilterComboBoxRenderer
()

Constructs a Renderer for types ComboBox.

protected JPanel

Returns:

the list
createList
(JFileChooser
a JFileChooser
fc
)

Constructs a details view.

public ListSelectionListener

Returns:

a ListSelectionListener
createListSelectionListener
(JFileChooser
a JFileChooser
fc
)

Overrides javax.swing.plaf.basic.BasicFileChooserUI.createListSelectionListener.

Creates a selection listener for the list of files and directories.

public PropertyChangeListener
public static ComponentUI

Returns:

a new instance of MetalFileChooserUI
createUI
(JComponent
a component
c
)

Hides javax.swing.plaf.basic.BasicFileChooserUI.createUI.

Constructs a new instance of MetalFileChooserUI.

private void
private void
private void
private void
private void
private void
private void
private void
private void
private void
public void
private String
private String
protected ActionMap

Returns:

an instance of ActionMap
getActionMap
()

Hides javax.swing.plaf.basic.BasicFileChooserUI.getActionMap.

Returns an instance of ActionMap.

protected JButton
protected JPanel

Returns:

the bottom panel
getBottomPanel
()

Returns the bottom panel.

protected JPanel

Returns:

the button panel
getButtonPanel
()

Returns the button panel.

public String

Returns:

the directory name
getDirectoryName
()

Overrides javax.swing.plaf.basic.BasicFileChooserUI.getDirectoryName.

Returns the directory name.

public String
public Dimension

Returns:

a Dimension specifying the maximum width and height of the file chooser
getMaximumSize
(JComponent
a JFileChooser
c
)

Overrides javax.swing.plaf.ComponentUI.getMaximumSize.

Returns the maximum size of the JFileChooser.

public Dimension

Returns:

a Dimension specifying the minimum width and height of the file chooser
getMinimumSize
(JComponent
a JFileChooser
c
)

Overrides javax.swing.plaf.ComponentUI.getMinimumSize.

Returns the minimum size of the JFileChooser.

private Integer
getMnemonic(String key, Locale l)

Hides javax.swing.plaf.basic.BasicFileChooserUI.getMnemonic.

Returns the mnemonic for the given key.

public Dimension

Returns:

a Dimension specifying the preferred width and height of the file chooser
getPreferredSize
(JComponent
a JFileChooser
c
)

Overrides javax.swing.plaf.ComponentUI.getPreferredSize.

Returns the preferred size of the specified JFileChooser.

private static void
public void
protected void
protected void
public void
private void
protected void
removeControlButtons()

Removes control buttons from bottom panel.

public void
public void
setDirectoryName(String
the directory name
dirname
)

Overrides javax.swing.plaf.basic.BasicFileChooserUI.setDirectoryName.

Sets the directory name.

protected void
setDirectorySelected(boolean
if a directory is currently selected.
directorySelected
)

Overrides javax.swing.plaf.basic.BasicFileChooserUI.setDirectorySelected.

Property to remember whether a directory is currently selected in the UI.

public void
public void
public void
public void
valueChanged(ListSelectionEvent
an instance of ListSelectionEvent
e
)

Invokes when ListSelectionEvent occurs.

Inherited from javax.swing.plaf.basic.BasicFileChooserUI:
clearIconCachecreateDoubleClickListenercreateModelgetAcceptAllFileFiltergetAccessoryPanelgetApproveButtonMnemonicgetApproveButtonTextgetApproveButtonToolTipTextgetApproveSelectionActiongetCancelSelectionActiongetChangeToParentDirectoryActiongetDefaultButtongetDialogTitlegetDirectorygetFileChoosergetFileViewgetGoHomeActiongetModelgetNewFolderActiongetUpdateActioninstallDefaultsinstallIconsisDirectorySelectedsetDirectoryuninstallDefaultsuninstallIconsuninstallListenersuninstallStrings