com.tensegrity.gui.swt.dialog
Class SwtInputDialog

java.lang.Object
  extended byorg.eclipse.swt.widgets.Dialog
      extended bycom.tensegrity.gui.swt.dialog.SwtBaseDialog
          extended bycom.tensegrity.gui.swt.dialog.SwtInputDialog
All Implemented Interfaces:
Disposable, Evaluable, java.util.EventListener, org.eclipse.swt.events.KeyListener, org.eclipse.swt.internal.SWTEventListener

public class SwtInputDialog
extends SwtBaseDialog

An SwtInputDialog is a dialog containing a text area for the user input, one Ok button and one Cancel button. The value entered by the user can be retrieved by means of the getValue() method.

Notice that the caller should dispose the dialog once it does not require it anymore.

Version:
$Id: SwtInputDialog.java,v 1.6 2005/11/09 11:34:18 ArndHouben Exp $
Author:
S�bastien Guyon

Field Summary
 
Fields inherited from class com.tensegrity.gui.swt.dialog.SwtBaseDialog
resourceClass, resourcePath
 
Constructor Summary
SwtInputDialog(UIManager uiManager, org.eclipse.swt.widgets.Display display, int style, java.lang.String keyTitle, java.lang.String keyDescription)
           Creates and initializes the SwtInputDialog with a text field for the user input and two buttons (Ok, Cancel).
SwtInputDialog(UIManager uiManager, org.eclipse.swt.widgets.Display display, java.lang.String keyTitle, java.lang.String keyDescription)
           Creates and initializes the SwtInputDialog with a text field for the user input and two buttons (Ok, Cancel).
 
Method Summary
 java.lang.String getValue()
           Returns the value of this input dialog.
 
Methods inherited from class com.tensegrity.gui.swt.dialog.SwtBaseDialog
applyEvList, dispose, getDialog, getTextCompositeLayoutData, getUIManager, installEvList, keyPressed, keyReleased, setDefaultResourceClassAndURL, setDescriptionText, setResourceClassAndURL, setTitleText, show
 
Methods inherited from class org.eclipse.swt.widgets.Dialog
checkSubclass, getParent, getStyle, getText, setText
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SwtInputDialog

public SwtInputDialog(UIManager uiManager,
                      org.eclipse.swt.widgets.Display display,
                      int style,
                      java.lang.String keyTitle,
                      java.lang.String keyDescription)

Creates and initializes the SwtInputDialog with a text field for the user input and two buttons (Ok, Cancel).

Parameters:
uiManager - a UIManager for localized Strings
display - a Display required for example to create the logo used on the dialog, or to create Fonts.
style - the style of the internal Shell representing the dialog.
keyTitle - the key used for the localized title of the dialog
keyDescription - the key used for the localized desciption of the dialog

SwtInputDialog

public SwtInputDialog(UIManager uiManager,
                      org.eclipse.swt.widgets.Display display,
                      java.lang.String keyTitle,
                      java.lang.String keyDescription)

Creates and initializes the SwtInputDialog with a text field for the user input and two buttons (Ok, Cancel). Notice that with this constructor the style used is SWT.DIALOG_TRIM | SWT.APPLICATION_MODAL.

Parameters:
uiManager - a UIManager for localized Strings
display - a Display required for example to create the logo used on the dialog, or to create Fonts.
keyTitle - the key used for the localized title of the dialog
keyDescription - the key used for the localized desciption of the dialog
Method Detail

getValue

public final java.lang.String getValue()

Returns the value of this input dialog.

Returns:
the value of this input dialog, null if the user cancelled


Copyright © 2005 Tensegrity Software GmbH. All Rights Reserved. Date of creation: 09.06.2006.