com.jidesoft.plaf.metal
Class MetalMenuUI
java.lang.Object
javax.swing.plaf.ComponentUI
javax.swing.plaf.ButtonUI
javax.swing.plaf.MenuItemUI
com.jidesoft.plaf.metal.MetalMenuItemUI
com.jidesoft.plaf.metal.MetalMenuUI
- Direct Known Subclasses:
- MetalJideSplitButtonUI
public class MetalMenuUI
- extends MetalMenuItemUI
A metal L&F implementation of MenuUI.
Nested Class Summary |
class |
MetalMenuUI.ChangeHandler
As of Java 2 platform 1.4, this previously undocumented class is now obsolete. |
protected class |
MetalMenuUI.MouseInputHandler
Instantiated and used by a menu item to handle the current menu selection from mouse events. |
Fields inherited from class com.jidesoft.plaf.metal.MetalMenuItemUI |
_painter, acceleratorFont, acceleratorForeground, acceleratorSelectionForeground, arrowIcon, checkIcon, defaultTextIconGap, disabledForeground, menuDragMouseListener, menuItem, menuKeyListener, mouseInputListener, oldBorderPainted, selectionBackground, selectionForeground |
Methods inherited from class com.jidesoft.plaf.metal.MetalMenuItemUI |
doClick, getMinimumSize, getPainter, getPath, getPreferredMenuItemSize, getRightMargin, installComponents, installUI, isDownArrowVisible, paint, paintMenuItem, paintText, uninstallComponents, uninstallUI, update |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
changeListener
protected ChangeListener changeListener
propertyChangeListener
protected PropertyChangeListener propertyChangeListener
menuListener
protected MenuListener menuListener
MetalMenuUI
public MetalMenuUI()
createUI
public static ComponentUI createUI(JComponent x)
installDefaults
protected void installDefaults()
- Overrides:
installDefaults
in class MetalMenuItemUI
getPropertyPrefix
protected String getPropertyPrefix()
- Overrides:
getPropertyPrefix
in class MetalMenuItemUI
installListeners
protected void installListeners()
- Overrides:
installListeners
in class MetalMenuItemUI
installKeyboardActions
protected void installKeyboardActions()
- Overrides:
installKeyboardActions
in class MetalMenuItemUI
uninstallKeyboardActions
protected void uninstallKeyboardActions()
- Overrides:
uninstallKeyboardActions
in class MetalMenuItemUI
createMouseInputListener
protected MouseInputListener createMouseInputListener(JComponent c)
- Overrides:
createMouseInputListener
in class MetalMenuItemUI
createMenuListener
protected MenuListener createMenuListener(JComponent c)
createChangeListener
protected ChangeListener createChangeListener(JComponent c)
createPropertyChangeListener
protected PropertyChangeListener createPropertyChangeListener(JComponent c)
uninstallDefaults
protected void uninstallDefaults()
- Overrides:
uninstallDefaults
in class MetalMenuItemUI
uninstallListeners
protected void uninstallListeners()
- Overrides:
uninstallListeners
in class MetalMenuItemUI
createMenuDragMouseListener
protected MenuDragMouseListener createMenuDragMouseListener(JComponent c)
- Overrides:
createMenuDragMouseListener
in class MetalMenuItemUI
createMenuKeyListener
protected MenuKeyListener createMenuKeyListener(JComponent c)
- Overrides:
createMenuKeyListener
in class MetalMenuItemUI
getMaximumSize
public Dimension getMaximumSize(JComponent c)
- Overrides:
getMaximumSize
in class MetalMenuItemUI
setupPostTimer
protected static void setupPostTimer(JMenu menu)
appendPath
protected static void appendPath(MenuElement[] path,
MenuElement elem)
setMouseOver
protected void setMouseOver(boolean over)
- Set the temporary flag to indicate if the mouse has entered the menu.
isMouseOver
protected boolean isMouseOver()
- Get the temporary flag to indicate if the mouse has entered the menu.
getPreferredSize
public Dimension getPreferredSize(JComponent c)
- Overrides:
getPreferredSize
in class MetalMenuItemUI
paintBackground
protected void paintBackground(Graphics g,
JMenuItem menuItem,
Color bgColor)
- Draws the background of the menu item.
- Overrides:
paintBackground
in class MetalMenuItemUI
- Parameters:
g
- the paint graphicsmenuItem
- menu item to be paintedbgColor
- selection background color- Since:
- 1.4