net.sourceforge.jiu.gui.awt.dialogs
Class GammaCorrectionDialog
Dialog
net.sourceforge.jiu.gui.awt.dialogs.GammaCorrectionDialog
- ActionListener, KeyListener
public class GammaCorrectionDialog
extends Dialog
implements ActionListener, KeyListener
A dialog to enter the parameters for a gamma correction operation.
MAX_GAMMA
private final double MAX_GAMMA
cancel
private Button cancel
gammaTextField
private TextField gammaTextField
pressedOk
private boolean pressedOk
result
private Double result
GammaCorrectionDialog
public GammaCorrectionDialog(Frame owner,
Strings strings,
double initialValue,
double maxGamma)
Creates a GammaCorrectionDialog.
owner
- the Frame this dialog will belong tostrings
- Strings resource used for text messagesinitialValue
- the value to be set when the dialog pops upmaxGamma
- the maximum allowed gamma value
actionPerformed
public void actionPerformed(ActionEvent e)
Hides (closes) this dialog if the OK button was source of the action event
(e.g. if the button was pressed).
getValue
public Double getValue()
getValue
private Double getValue(TextField tf)
handleKeys
public void handleKeys(KeyEvent e)
hasPressedOk
public boolean hasPressedOk()
keyPressed
public void keyPressed(KeyEvent e)
keyReleased
public void keyReleased(KeyEvent e)
keyTyped
public void keyTyped(KeyEvent e)