All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.bulletproof.gui.PopupMenu

java.lang.Object
   |
   +----com.bulletproof.gui.Component
           |
           +----com.bulletproof.gui.PopupMenu

public class PopupMenu
extends Component
implements ItemListener
Class PopupMenu represents a class for displaying a popup menu component.


Constructor Index

 o PopupMenu(Frame)
Creates a PopupMenu Component.

Method Index

 o addActionListener(ActionListener)
 o addItem(String)
Add an item to the menu.
 o deselectAll()
 o display(int, int)
 o getItem(int)
Gets the displayed value of the specified item.
 o getSelectedItem()
 o hide()
 o itemStateChanged(ItemEvent)
 o removeActionListener(ActionListener)
 o setItem(int, String)
Sets the displayed value of the specified item.

Constructors

 o PopupMenu
 public PopupMenu(Frame parent)
Creates a PopupMenu Component.

Parameters:
parent - the parent component that is responsible for this popup.

Methods

 o addActionListener
 public void addActionListener(ActionListener al)
 o removeActionListener
 public void removeActionListener(ActionListener al)
 o getItem
 public String getItem(int index)
Gets the displayed value of the specified item.

Parameters:
index - the item number to set the new text.
Returns:
the text of the item.
 o setItem
 public void setItem(int index,
                     String displayItem)
Sets the displayed value of the specified item.

Parameters:
index - the item number to set the new text.
displayItem - the text of the item.
 o addItem
 public void addItem(String menuItem)
Add an item to the menu.

Parameters:
menuItem - the text of the menu item.
 o deselectAll
 public void deselectAll()
 o getSelectedItem
 public String getSelectedItem()
 o hide
 public void hide()
 o itemStateChanged
 public void itemStateChanged(ItemEvent e)
 o display
 public void display(int xpos,
                     int ypos)

All Packages  Class Hierarchy  This Package  Previous  Next  Index