Class ibm.aglets.util.GeneralDialog
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class ibm.aglets.util.GeneralDialog

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----java.awt.Window
                           |
                           +----java.awt.Dialog
                                   |
                                   +----ibm.aglets.util.GeneralDialog

public class GeneralDialog
extends Dialog
The GeneralDialog class is a common and generic dialog to display the messages

Variable Index

 o ALWAYS_CENTER
 o APPLY
 o CANCEL
 o CENTER_ONLY_ONCE
 o FREE
 o HELP
 o OKAY

Constructor Index

 o GeneralDialog(Frame, Component, String, Object, boolean)

Method Index

 o addButton(Button)
Adds extra button you like.
 o addCmp(Component, GridBagLayout, GridBagConstraints)
 o beep()
Rings a bell.
 o getButton(int)
Obtains dialog button
 o getTitleLabel()
 o handleEvent(Event)
Handles the events.
 o layoutComponents()
 o makePanel(GridBagLayout)
 o onApply()
 o onCancel()
 o onHelp()
 o onOkay()
 o pack()
 o popup(Frame)
Pops up the dialog window so that it get located at the center of the frame.
 o popup(int)
Pops up the dialog window according to the location given as a parameter
 o postCallbackEvent(Event)
 o setButtons(int)
Specifies which buttons should be appeared on the bottom of window.
 o setCallbackComponent(Component)
 o waitForDisplay()
Waits until the dialog window is actually shown.
 o waitForDisposal()
Waits until the dialog window is disposed.

Variables

 o OKAY
  public final static int OKAY
 o CANCEL
  public final static int CANCEL
 o APPLY
  public final static int APPLY
 o HELP
  public final static int HELP
 o ALWAYS_CENTER
  public final static int ALWAYS_CENTER
 o CENTER_ONLY_ONCE
  public final static int CENTER_ONLY_ONCE
 o FREE
  public final static int FREE

Constructors

 o GeneralDialog
  public GeneralDialog(Frame parent,
                       Component callback_component,
                       String title,
                       Object object,
                       boolean modal)

Methods

 o setCallbackComponent
  protected void setCallbackComponent(Component c)
 o postCallbackEvent
  protected void postCallbackEvent(Event ev)
 o layoutComponents
  protected final void layoutComponents()
 o getTitleLabel
  public Label getTitleLabel()
 o makePanel
  protected abstract void makePanel(GridBagLayout grid)
 o addCmp
  protected void addCmp(Component c,
                        GridBagLayout grid,
                        GridBagConstraints cns)
 o popup
  public void popup(Frame frame)
Pops up the dialog window so that it get located at the center of the frame. If frame is null, parent frame will be used.
 o popup
  public void popup(int location)
Pops up the dialog window according to the location given as a parameter
 o handleEvent
  public boolean handleEvent(Event event)
Handles the events.
Overrides:
handleEvent in class Component
 o onOkay
  protected boolean onOkay()
 o onCancel
  protected boolean onCancel()
 o onHelp
  protected boolean onHelp()
 o onApply
  protected boolean onApply()
 o waitForDisposal
  public void waitForDisposal() throws InterruptedException
Waits until the dialog window is disposed.
 o waitForDisplay
  public void waitForDisplay() throws InterruptedException
Waits until the dialog window is actually shown.
 o beep
  public void beep()
Rings a bell. This is a tentative method and this should move to more common class for aglets.
 o setButtons
  public void setButtons(int b)
Specifies which buttons should be appeared on the bottom of window.
Parameters:
b - logical OR value of constants, OKAY, CANCEL, HELP, APPLY.
 o addButton
  public void addButton(Button b)
Adds extra button you like.
Parameters:
b - the button to get added.
 o pack
  public void pack()
Overrides:
pack in class Window
 o getButton
  public Button getButton(int b)
Obtains dialog button

All Packages  Class Hierarchy  This Package  Previous  Next  Index