javax.swing.plaf.metal

Class MetalInternalFrameUI


public class MetalInternalFrameUI
extends BasicInternalFrameUI

A UI delegate for the JInternalFrame component.

Nested Class Summary

Nested classes/interfaces inherited from class javax.swing.plaf.basic.BasicInternalFrameUI

BasicInternalFrameUI.BasicInternalFrameListener, BasicInternalFrameUI.BorderListener, BasicInternalFrameUI.ComponentHandler, BasicInternalFrameUI.GlassPaneDispatcher, BasicInternalFrameUI.InternalFrameLayout, BasicInternalFrameUI.InternalFramePropertyChangeListener

Field Summary

protected static String
IS_PALETTE
The key (JInternalFrame.isPalette) for the client property that controls whether the internal frame is displayed using the palette style.

Fields inherited from class javax.swing.plaf.basic.BasicInternalFrameUI

borderListener, componentListener, eastPane, frame, glassPaneDispatcher, internalFrameLayout, northPane, openMenuKey, propertyChangeListener, southPane, titlePane, westPane

Constructor Summary

MetalInternalFrameUI(JInternalFrame frame)
Constructs a new instance of MetalInternalFrameUI.

Method Summary

protected JComponent
createNorthPane(JInternalFrame w)
Creates and returns the component that will be used for the north pane of the JInternalFrame.
static ComponentUI
createUI(JComponent component)
Returns an instance of MetalInternalFrameUI.
protected void
installKeyboardActions()
Installs keyboard actions.
protected void
installListeners()
Adds the required listeners.
void
installUI(JComponent c)
Sets the fields and properties for the component.
void
setPalette(boolean isPalette)
Sets the state of the JInternalFrame to reflect whether or not it is using the palette style.
protected void
uninstallListeners()
Removes the listeners used.

Methods inherited from class javax.swing.plaf.basic.BasicInternalFrameUI

activateFrame, closeFrame, createBorderListener, createComponentListener, createDesktopManager, createEastPane, createGlassPaneDispatcher, createInternalFrameListener, createLayoutManager, createNorthPane, createPropertyChangeListener, createSouthPane, createUI, createWestPane, deactivateFrame, deiconifyFrame, deinstallMouseHandlers, getDesktopManager, getEastPane, getMaximumSize, getMinimumSize, getNorthPane, getPreferredSize, getSouthPane, getWestPane, iconifyFrame, installComponents, installDefaults, installKeyboardActions, installListeners, installMouseHandlers, installUI, isKeyBindingActive, isKeyBindingRegistered, maximizeFrame, minimizeFrame, replacePane, setEastPane, setKeyBindingActive, setKeyBindingRegistered, setNorthPane, setSouthPane, setWestPane, setupMenuCloseKey, setupMenuOpenKey, uninstallComponents, uninstallDefaults, uninstallKeyboardActions, uninstallListeners, uninstallUI

Methods inherited from class javax.swing.plaf.ComponentUI

contains, createUI, getAccessibleChild, getAccessibleChildrenCount, getMaximumSize, getMinimumSize, getPreferredSize, installUI, paint, uninstallUI, update

Methods inherited from class java.lang.Object

clone, equals, extends Object> getClass, finalize, hashCode, notify, notifyAll, toString, wait, wait, wait

Field Details

IS_PALETTE

protected static String IS_PALETTE
The key (JInternalFrame.isPalette) for the client property that controls whether the internal frame is displayed using the palette style.

Constructor Details

MetalInternalFrameUI

public MetalInternalFrameUI(JInternalFrame frame)
Constructs a new instance of MetalInternalFrameUI.
Parameters:
frame - the frame.

Method Details

createNorthPane

protected JComponent createNorthPane(JInternalFrame w)
Creates and returns the component that will be used for the north pane of the JInternalFrame.
Overrides:
createNorthPane in interface BasicInternalFrameUI
Parameters:
w - the internal frame.
Returns:
A new instance of MetalInternalFrameTitlePane.

createUI

public static ComponentUI createUI(JComponent component)
Returns an instance of MetalInternalFrameUI.
Overrides:
createUI in interface BasicInternalFrameUI
Parameters:
component - the internal frame.
Returns:
an instance of MetalInternalFrameUI.

installKeyboardActions

protected void installKeyboardActions()
Installs keyboard actions. This is overridden to remove the showSystemMenu Action that is installed by the BasicInternalFrameUI, since Metal JInternalFrames don't have a system menu.
Overrides:
installKeyboardActions in interface BasicInternalFrameUI

installListeners

protected void installListeners()
Adds the required listeners.
Overrides:
installListeners in interface BasicInternalFrameUI

installUI

public void installUI(JComponent c)
Sets the fields and properties for the component.
Overrides:
installUI in interface BasicInternalFrameUI
Parameters:
c - the component.

setPalette

public void setPalette(boolean isPalette)
Sets the state of the JInternalFrame to reflect whether or not it is using the palette style. When a frame is displayed as a palette, it uses a different border and the title pane is drawn differently.
Parameters:
isPalette - use the palette style?

uninstallListeners

protected void uninstallListeners()
Removes the listeners used.
Overrides:
uninstallListeners in interface BasicInternalFrameUI

MetalInternalFrameUI.java Copyright (C) 2005 Free Software Foundation, Inc. This file is part of GNU Classpath. GNU Classpath is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2, or (at your option) any later version. GNU Classpath is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with GNU Classpath; see the file COPYING. If not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. Linking this library statically or dynamically with other modules is making a combined work based on this library. Thus, the terms and conditions of the GNU General Public License cover the whole combination. As a special exception, the copyright holders of this library give you permission to link this library with independent modules to produce an executable, regardless of the license terms of these independent modules, and to copy and distribute the resulting executable under terms of your choice, provided that you also meet, for each linked independent module, the terms and conditions of the license of that module. An independent module is a module which is not derived from or based on this library. If you modify this library, you may extend this exception to your version of the library, but you are not obligated to do so. If you do not wish to do so, delete this exception statement from your version.