Class JMenuStatusBarItem

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible

public class JMenuStatusBarItem extends StatusBarItem
A status bar item with an icon which displays a pop-up menu when clicked.
Since:
8.0
Author:
Michael Bedward
See Also:
  • Constructor Details

    • JMenuStatusBarItem

      public JMenuStatusBarItem(String name, ImageIcon icon, String toolTip, JPopupMenu menu)
      Creates a new item to display the given menu;
      Parameters:
      name - the item name
      icon - the icon to display
      toolTip - tool tip text (may be null
      menu - the pop-up menu to launch when the item is clicked
      Throws:
      IllegalArgumentException - if icon or menu are null
    • JMenuStatusBarItem

      public JMenuStatusBarItem(String name, ImageIcon icon, String toolTip, PopupMenuProvider menuProvider)
      Creates a new item to display a menu which will be supplired by menuProvider.
      Parameters:
      name - the item name
      icon - the icon to display
      menuProvider - an object to provide a (possibly dynamic) pop-up menu
      Throws:
      IllegalArgumentException - if icon or menuPRovider are null