All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class Acme.Widgets.ButtonDialog

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----java.awt.Window
                           |
                           +----java.awt.Dialog
                                   |
                                   +----Acme.Widgets.ButtonDialog

public class ButtonDialog
extends Dialog
implements Runnable
A generic modal button box.

Puts up a dialog with a message and client-specified buttons. All user input is locked out. The program can retrieve the user's answer via the getAnswer() method.

NOTE: do not use this inside an event handler call! With some browsers this will cause a deadlock. Instead, have your event handler start a new thread to run the button box.

Fetch the software.
Fetch the entire Acme package.


Constructor Index

 o ButtonDialog(Frame, String, String, int)
Constructor, no title, one button.
 o ButtonDialog(Frame, String, String, int, String, int)
Constructor, no title, two buttons.
 o ButtonDialog(Frame, String, String, int, String, int, String, int)
Constructor, no title, three buttons.
 o ButtonDialog(Frame, String, String, int, String, int, String, int, String, int)
Constructor, no title, four buttons.
 o ButtonDialog(Frame, String, String, String, int)
Constructor, specified title, one button.
 o ButtonDialog(Frame, String, String, String, int, String, int)
Constructor, specified title, two buttons.
 o ButtonDialog(Frame, String, String, String, int, String, int, String, int)
Constructor, specified title, three buttons.
 o ButtonDialog(Frame, String, String, String, int, String, int, String, int, String, int)
Constructor, specified title, four buttons.

Method Index

 o getAnswer()
Get the answer.
 o handleEvent(Event)
Event handler.
 o run()
 o show()
Show the box.

Constructors

 o ButtonDialog
 public ButtonDialog(Frame parent,
                     String message,
                     String button1,
                     int answer1)
Constructor, no title, one button.

 o ButtonDialog
 public ButtonDialog(Frame parent,
                     String title,
                     String message,
                     String button1,
                     int answer1)
Constructor, specified title, one button.

 o ButtonDialog
 public ButtonDialog(Frame parent,
                     String message,
                     String button1,
                     int answer1,
                     String button2,
                     int answer2)
Constructor, no title, two buttons.

 o ButtonDialog
 public ButtonDialog(Frame parent,
                     String title,
                     String message,
                     String button1,
                     int answer1,
                     String button2,
                     int answer2)
Constructor, specified title, two buttons.

 o ButtonDialog
 public ButtonDialog(Frame parent,
                     String message,
                     String button1,
                     int answer1,
                     String button2,
                     int answer2,
                     String button3,
                     int answer3)
Constructor, no title, three buttons.

 o ButtonDialog
 public ButtonDialog(Frame parent,
                     String title,
                     String message,
                     String button1,
                     int answer1,
                     String button2,
                     int answer2,
                     String button3,
                     int answer3)
Constructor, specified title, three buttons.

 o ButtonDialog
 public ButtonDialog(Frame parent,
                     String message,
                     String button1,
                     int answer1,
                     String button2,
                     int answer2,
                     String button3,
                     int answer3,
                     String button4,
                     int answer4)
Constructor, no title, four buttons.

 o ButtonDialog
 public ButtonDialog(Frame parent,
                     String title,
                     String message,
                     String button1,
                     int answer1,
                     String button2,
                     int answer2,
                     String button3,
                     int answer3,
                     String button4,
                     int answer4)
Constructor, specified title, four buttons.

Methods

 o show
 public void show()
Show the box.

Overrides:
show in class Dialog
 o run
 public void run()
 o handleEvent
 public boolean handleEvent(Event evt)
Event handler.

Overrides:
handleEvent in class Component
 o getAnswer
 public synchronized int getAnswer()
Get the answer.


All Packages  Class Hierarchy  This Package  Previous  Next  Index

ACME Java  ACME Labs