Class marimba.gui.DropDownMenu
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class marimba.gui.DropDownMenu

java.lang.Object
   |
   +----marimba.gui.Widget
           |
           +----marimba.gui.ContainerWidget
                   |
                   +----marimba.gui.GroupWidget
                           |
                           +----marimba.gui.PopupWidget
                                   |
                                   +----marimba.gui.PopupMenu
                                           |
                                           +----marimba.gui.DropDownMenu

public class DropDownMenu
extends PopupMenu
A simple drop down menu.
Version:
1.24, 01/19/97
Author:
Klaas Waslander

Variable Index

 o w
The widget that uses this DropDownMenu.

Constructor Index

 o DropDownMenu(Widget, String[], boolean)
Constructor without setting the max number of visible items.
 o DropDownMenu(Widget, String[], boolean, int)
Constructor: Show a dropDownMenu that belongs to the given widget.

Method Index

 o handleEvent(Event)
Handle mouse events.
 o nextItem()
Select next item, do not loop around when the last item has been reached.
 o previousItem()
Select previous item, do not loop around when the first item has been reached.

Variables

 o w
  public Widget w
The widget that uses this DropDownMenu. This class sets the current value of this widget and invokes the w.action() method when a choice is being made out of the available choices of this DropDownMenu. The value is being set using w.setValue(new Integer(int)) where "int" is the index of the choice that was made.

Constructors

 o DropDownMenu
  public DropDownMenu(Widget w,
                      String choices[],
                      boolean autoSize)
Constructor without setting the max number of visible items.
Parameters:
autoSize - if false, the width of the choicewidget is used.
 o DropDownMenu
  public DropDownMenu(Widget w,
                      String choices[],
                      boolean autoSize,
                      int maxVisible)
Constructor: Show a dropDownMenu that belongs to the given widget. The items that should be in this menu are passed in the parameter called "choices".
Parameters:
autoSize - if false, the width of the choicewidget is used.

Methods

 o nextItem
  public void nextItem()
Select next item, do not loop around when the last item has been reached.
Overrides:
nextItem in class PopupMenu
See Also:
current
 o previousItem
  public void previousItem()
Select previous item, do not loop around when the first item has been reached.
Overrides:
previousItem in class PopupMenu
See Also:
current
 o handleEvent
  public boolean handleEvent(Event evt)
Handle mouse events.
Overrides:
handleEvent in class PopupMenu

All Packages  Class Hierarchy  This Package  Previous  Next  Index