Package net.sourceforge.jiu.gui.awt.dialogs

# Class Dialogs

java.lang.Object
net.sourceforge.jiu.gui.awt.dialogs.Dialogs

public class Dialogs extends Object
Convenience class that provides a number of static helper methods to deal with dialogs.

Author:
  Marco Schmidt

## Constructor Summary

Constructors
Modifier
Constructor
Description
`private`
`Dialogs()`

## Method Summary

Modifier and Type
Method
Description
`static void`
`center(Window window)`
Centers the argument window on screen.
`static Integer`
`getInteger(Frame owner, String title, String message, int minValue, int initialValue, int maxValue, String okText, String cancelText)`
Creates a new IntegerDialog, displays it and returns the Integer value specified by the user (or null if the dialog was canceled).

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### Dialogs

private Dialogs()

## Method Details

### center

public static void center(Window window)
Centers the argument window on screen.

### getInteger

public static Integer getInteger(Frame owner, String title, String message, int minValue, int initialValue, int maxValue, String okText, String cancelText)
Creates a new IntegerDialog, displays it and returns the Integer value specified by the user (or null if the dialog was canceled).

Parameters:
  `owner` - frame from which the dialog is spawned
  `title` - text for the title bar of the dialog
  `message` - message displayed in the dialog
  `minValue` - minimal allowed integer value to be entered by the user
  `initialValue` - initial integer value shown in the dialog
  `maxValue` - maximal allowed integer value to be entered by the user
  `okText` - the text for the OK button
  `cancelText` - the text for the cancel button
Returns:
  the specified integer value or null if the Cancel button was pressed