/Users/lyon/j4p/src/ip/gui/dialog/GrayLog.java

1    package ip.gui.dialog; 
2     
3    import ip.gui.frames.NegateFrame; 
4     
5    import java.awt.event.ActionEvent; 
6     
7    public class GrayLog extends DoubleLog { 
8        private NegateFrame parent; 
9     
10       public GrayLog( 
11               NegateFrame _parent, 
12               String title, 
13               String prompts[], 
14               String defaults[], 
15               int fieldSize) { 
16           super(_parent, title, prompts, defaults, fieldSize); 
17           parent = _parent; 
18           setButton.addActionListener(this); 
19           cancelButton.addActionListener(this); 
20       } 
21    
22       public void actionPerformed(ActionEvent e) { 
23           if (e.getSource() == setButton) { 
24               double dui[] = getUserInputAsDouble(); 
25               parent.linearTransform(dui[0], dui[1]); 
26               return; 
27           } 
28           super.actionPerformed(e); 
29       } 
30   } 
31