net.openai.ai.nn.gui.widgets
Class AIPopupMenu

java.lang.Object
  |
  +--java.awt.MenuComponent
        |
        +--java.awt.MenuItem
              |
              +--java.awt.Menu
                    |
                    +--java.awt.PopupMenu
                          |
                          +--net.openai.ai.nn.gui.widgets.AIPopupMenu
All Implemented Interfaces:
javax.accessibility.Accessible, java.awt.MenuContainer, java.io.Serializable

public class AIPopupMenu
extends java.awt.PopupMenu

Helperclass for simple PopupMenus The class registers itself as listener to all JMenu entries. Event are forwareded then to all registered PopupMenuListener's

Version:
$Id: AIPopupMenu.java,v 1.1 2002/02/28 17:12:14 tweber Exp $ History:
$Log: AIPopupMenu.java,v $
Revision 1.1 2002/02/28 17:12:14 tweber
moved to .widget package

Revision 1.3 2002/02/14 23:22:45 gleo
Jindent run through.

Revision 1.2 2002/02/13 09:13:12 tweber
Reformated by Jindent

Revision 1.1 2002/01/15 23:31:41 gleo
adding files to conform to naming conventions and some new updates
Author:
Thomas Weber
See Also:
Serialized Form

Nested Class Summary
 
Nested classes inherited from class java.awt.PopupMenu
java.awt.PopupMenu.AccessibleAWTPopupMenu
 
Nested classes inherited from class java.awt.Menu
java.awt.Menu.AccessibleAWTMenu
 
Nested classes inherited from class java.awt.MenuItem
java.awt.MenuItem.AccessibleAWTMenuItem
 
Nested classes inherited from class java.awt.MenuComponent
java.awt.MenuComponent.AccessibleAWTMenuComponent
 
Constructor Summary
AIPopupMenu()
          Constructs a new PopupMenu Object
AIPopupMenu(java.lang.String label)
          Constructs a new PopupMenu Object with the given title
AIPopupMenu(java.lang.String label, AIPopupMenuListener l)
          Constructor declaration
 
Method Summary
 void add(java.lang.String Name, java.lang.String Text)
          Add a new entry to the Popup-menu The name of the entry is later used as CommandName for ActionEvents
 void add(java.lang.String Name, java.lang.String Text, int mnemonic)
          Add a new entry to the Popup-menu The name of the entry is later used as CommandName for ActionEvents
 void addPopupMenuListeners(AIPopupMenuListener l)
          Add a listener to the eventlist
 void firePopupEvent(java.awt.event.ActionEvent e)
          Forwards a event to all listeners.
 void removePopupMenuListeners(AIPopupMenuListener l)
          Remove a listener from the eventlist
 
Methods inherited from class java.awt.PopupMenu
addNotify, getAccessibleContext, show
 
Methods inherited from class java.awt.Menu
add, add, addSeparator, countItems, getItem, getItemCount, insert, insert, insertSeparator, isTearOff, paramString, remove, remove, removeAll, removeNotify
 
Methods inherited from class java.awt.MenuItem
addActionListener, deleteShortcut, disable, disableEvents, enable, enable, enableEvents, getActionCommand, getActionListeners, getLabel, getListeners, getShortcut, isEnabled, processActionEvent, processEvent, removeActionListener, setActionCommand, setEnabled, setLabel, setShortcut
 
Methods inherited from class java.awt.MenuComponent
dispatchEvent, getFont, getName, getParent, getPeer, getTreeLock, postEvent, setFont, setName, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
 

Constructor Detail

AIPopupMenu

public AIPopupMenu()
Constructs a new PopupMenu Object


AIPopupMenu

public AIPopupMenu(java.lang.String label)
Constructs a new PopupMenu Object with the given title


AIPopupMenu

public AIPopupMenu(java.lang.String label,
                   AIPopupMenuListener l)
Constructor declaration

Parameters:
label -
l -
Method Detail

addPopupMenuListeners

public void addPopupMenuListeners(AIPopupMenuListener l)
Add a listener to the eventlist


removePopupMenuListeners

public void removePopupMenuListeners(AIPopupMenuListener l)
Remove a listener from the eventlist


firePopupEvent

public void firePopupEvent(java.awt.event.ActionEvent e)
Forwards a event to all listeners.


add

public void add(java.lang.String Name,
                java.lang.String Text)
Add a new entry to the Popup-menu The name of the entry is later used as CommandName for ActionEvents

Parameters:
Name - Name for the menu. Also ID for CommandName in ActionEvents.
Text - Menucaption

add

public void add(java.lang.String Name,
                java.lang.String Text,
                int mnemonic)
Add a new entry to the Popup-menu The name of the entry is later used as CommandName for ActionEvents

Parameters:
Name - Name for the menu. Also ID for CommandName in ActionEvents.
Text - Menucaption
mnemonic - Shortcut for this entry


Copyright - 2001 OpenAI Labs. All Rights Reserved.