java.awt

Class PopupMenu

  • All Implemented Interfaces:
    MenuContainer, java.io.Serializable, javax.accessibility.Accessible
    public class PopupMenu extends Menu
    A class that implements a menu which can be dynamically popped up at a specified position within a component.

    As the inheritance hierarchy implies, a PopupMenu can be used anywhere a Menu can be used. However, if you use a PopupMenu like a Menu (e.g., you add it to a MenuBar), then you cannot call show on that PopupMenu.

    See Also:
    Serialized Form
    • Constructors 
      Constructor and Description
      Ordinary member indicator PopupMenu Reveal DetailHide Detail
      Creates a new popup menu with an empty name.
      Ordinary member indicator PopupMenu Reveal DetailHide Detail
      Creates a new popup menu with the specified name.
    • Methods 
      Modifier and Type Method and Description
      Inherited member indicator add Reveal DetailHide Detail
      Adds the specified menu item to this menu.
      Inherited member indicator add Reveal DetailHide Detail
      Adds an item with the specified label to this menu.
      Inherited member indicator addActionListener Reveal DetailHide Detail
      Adds the specified action listener to receive action events from this menu item.
      Overridden member indicator addNotify Reveal DetailHide Detail
      Creates the popup menu's peer.
      Inherited member indicator addSeparator Reveal DetailHide Detail
      Adds a separator line, or a hypen, to the menu at the current position.
      Inherited member indicator countItems Reveal DetailHide Detail
      Deprecated. As of JDK version 1.1, replaced by getItemCount().
      Inherited member indicator deleteShortcut Reveal DetailHide Detail
      Delete any MenuShortcut object associated with this menu item.
      Inherited member indicator disable Reveal DetailHide Detail
      Deprecated. As of JDK version 1.1, replaced by setEnabled(boolean).
      Inherited member indicator dispatchEvent Reveal DetailHide Detail
      Delivers an event to this component or one of its sub components.
      Inherited member indicator enable Reveal DetailHide Detail
      Deprecated. As of JDK version 1.1, replaced by setEnabled(boolean).
      Inherited member indicator enable Reveal DetailHide Detail
      Deprecated. As of JDK version 1.1, replaced by setEnabled(boolean).
      Overridden member indicator getAccessibleContext Reveal DetailHide Detail
      Gets the AccessibleContext associated with this PopupMenu.
      Inherited member indicator getActionCommand Reveal DetailHide Detail
      Gets the command name of the action event that is fired by this menu item.
      Inherited member indicator getActionListeners Reveal DetailHide Detail
      Returns an array of all the action listeners registered on this menu item.
      Inherited member indicator getFont Reveal DetailHide Detail
      Gets the font used for this menu component.
      Inherited member indicator getItem Reveal DetailHide Detail
      Gets the item located at the specified index of this menu.
      Inherited member indicator getItemCount Reveal DetailHide Detail
      Get the number of items in this menu.
      Inherited member indicator getLabel Reveal DetailHide Detail
      Gets the label for this menu item.
      Inherited member indicator getListeners Reveal DetailHide Detail
      Returns an array of all the objects currently registered as FooListeners upon this MenuItem.
      Inherited member indicator getName Reveal DetailHide Detail
      Gets the name of the menu component.
      Overridden member indicator getParent Reveal DetailHide Detail
      Returns the parent container for this menu component.
      Inherited member indicator getPeer Reveal DetailHide Detail
      Deprecated. As of JDK version 1.1, programs should not directly manipulate peers.
      Inherited member indicator getShortcut Reveal DetailHide Detail
      Get the MenuShortcut object associated with this menu item,
      Inherited member indicator insert Reveal DetailHide Detail
      Inserts a menu item into this menu at the specified position.
      Inherited member indicator insert Reveal DetailHide Detail
      Inserts a menu item with the specified label into this menu at the specified position.
      Inherited member indicator insertSeparator Reveal DetailHide Detail
      Inserts a separator at the specified position.
      Inherited member indicator isEnabled Reveal DetailHide Detail
      Checks whether this menu item is enabled.
      Inherited member indicator isTearOff Reveal DetailHide Detail
      Indicates whether this menu is a tear-off menu.
      Inherited member indicator paramString Reveal DetailHide Detail
      Returns a string representing the state of this Menu.
      Inherited member indicator postEvent Reveal DetailHide Detail
      Deprecated. As of JDK version 1.1, replaced by dispatchEvent.
      Inherited member indicator remove Reveal DetailHide Detail
      Removes the menu item at the specified index from this menu.
      Inherited member indicator remove Reveal DetailHide Detail
      Removes the specified menu item from this menu.
      Inherited member indicator removeActionListener Reveal DetailHide Detail
      Removes the specified action listener so it no longer receives action events from this menu item.
      Inherited member indicator removeAll Reveal DetailHide Detail
      Removes all items from this menu.
      Inherited member indicator removeNotify Reveal DetailHide Detail
      Removes the menu's peer.
      Inherited member indicator setActionCommand Reveal DetailHide Detail
      Sets the command name of the action event that is fired by this menu item.
      Inherited member indicator setEnabled Reveal DetailHide Detail
      Sets whether or not this menu item can be chosen.
      Inherited member indicator setFont Reveal DetailHide Detail
      Sets the font to be used for this menu component to the specified font.
      Inherited member indicator setLabel Reveal DetailHide Detail
      Sets the label for this menu item to the specified label.
      Inherited member indicator setName Reveal DetailHide Detail
      Sets the name of the component to the specified string.
      Inherited member indicator setShortcut Reveal DetailHide Detail
      Set the MenuShortcut object associated with this menu item.
      Ordinary member indicator show Reveal DetailHide Detail
      Shows the popup menu at the x, y position relative to an origin component.
      Inherited member indicator toString Reveal DetailHide Detail
      Returns a representation of this menu component as a string.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
This document was created by Dulcet from the OpenJDK sources. Copyright © 1993, 2012 Oracle and/or its affiliates. All rights reserved.

SourceForge