2 |
26 Feb 07 |
jari |
1 |
/* |
2 |
26 Feb 07 |
jari |
Copyright @ 1999-2005, The Institute for Genomic Research (TIGR). |
2 |
26 Feb 07 |
jari |
All rights reserved. |
2 |
26 Feb 07 |
jari |
4 |
*//* |
2 |
26 Feb 07 |
jari |
5 |
* DAMInitDialog.java |
2 |
26 Feb 07 |
jari |
6 |
* |
2 |
26 Feb 07 |
jari |
7 |
*/ |
2 |
26 Feb 07 |
jari |
8 |
|
2 |
26 Feb 07 |
jari |
9 |
package org.tigr.microarray.mev.cluster.gui.impl.dam; |
2 |
26 Feb 07 |
jari |
10 |
|
2 |
26 Feb 07 |
jari |
11 |
import java.awt.Color; |
2 |
26 Feb 07 |
jari |
12 |
import java.awt.Dimension; |
2 |
26 Feb 07 |
jari |
13 |
import java.awt.Font; |
2 |
26 Feb 07 |
jari |
14 |
import java.awt.GridBagConstraints; |
2 |
26 Feb 07 |
jari |
15 |
import java.awt.GridBagLayout; |
2 |
26 Feb 07 |
jari |
16 |
import java.awt.Insets; |
2 |
26 Feb 07 |
jari |
17 |
import java.awt.Toolkit; |
2 |
26 Feb 07 |
jari |
18 |
import java.awt.event.ActionEvent; |
2 |
26 Feb 07 |
jari |
19 |
import java.awt.event.WindowAdapter; |
2 |
26 Feb 07 |
jari |
20 |
import java.awt.event.WindowEvent; |
2 |
26 Feb 07 |
jari |
21 |
|
2 |
26 Feb 07 |
jari |
22 |
import javax.swing.ButtonGroup; |
2 |
26 Feb 07 |
jari |
23 |
import javax.swing.JCheckBox; |
2 |
26 Feb 07 |
jari |
24 |
import javax.swing.JLabel; |
2 |
26 Feb 07 |
jari |
25 |
import javax.swing.JOptionPane; |
2 |
26 Feb 07 |
jari |
26 |
import javax.swing.JPanel; |
2 |
26 Feb 07 |
jari |
27 |
import javax.swing.JRadioButton; |
2 |
26 Feb 07 |
jari |
28 |
import javax.swing.JTextField; |
2 |
26 Feb 07 |
jari |
29 |
import javax.swing.UIManager; |
2 |
26 Feb 07 |
jari |
30 |
import javax.swing.border.EtchedBorder; |
2 |
26 Feb 07 |
jari |
31 |
import javax.swing.border.TitledBorder; |
2 |
26 Feb 07 |
jari |
32 |
|
2 |
26 Feb 07 |
jari |
33 |
import org.tigr.microarray.mev.cluster.gui.impl.dialogs.AlgorithmDialog; |
2 |
26 Feb 07 |
jari |
34 |
import org.tigr.microarray.mev.cluster.gui.impl.dialogs.DialogListener; |
2 |
26 Feb 07 |
jari |
35 |
import org.tigr.microarray.mev.cluster.gui.impl.dialogs.SampleSelectionPanel; |
2 |
26 Feb 07 |
jari |
36 |
import org.tigr.microarray.mev.cluster.gui.impl.dialogs.dialogHelpUtil.HelpWindow; |
2 |
26 Feb 07 |
jari |
37 |
|
2 |
26 Feb 07 |
jari |
38 |
public class DAMInitDialog extends AlgorithmDialog { |
2 |
26 Feb 07 |
jari |
39 |
|
2 |
26 Feb 07 |
jari |
40 |
int result = JOptionPane.CANCEL_OPTION; |
2 |
26 Feb 07 |
jari |
41 |
|
2 |
26 Feb 07 |
jari |
42 |
boolean skipGeneScreeningStep = false; |
2 |
26 Feb 07 |
jari |
43 |
boolean skipCrossValidationStep = false; |
2 |
26 Feb 07 |
jari |
44 |
|
2 |
26 Feb 07 |
jari |
45 |
private SampleSelectionPanel sampleSelectionPanel; |
2 |
26 Feb 07 |
jari |
46 |
|
2 |
26 Feb 07 |
jari |
47 |
private JPanel assessPanel; |
2 |
26 Feb 07 |
jari |
48 |
private JPanel classPanel; |
2 |
26 Feb 07 |
jari |
49 |
private JPanel paramPanel; |
2 |
26 Feb 07 |
jari |
50 |
private JPanel processPanel; |
2 |
26 Feb 07 |
jari |
51 |
private JPanel assessSelectionPanel; |
2 |
26 Feb 07 |
jari |
52 |
|
2 |
26 Feb 07 |
jari |
53 |
private JCheckBox geneScreenBox; |
2 |
26 Feb 07 |
jari |
54 |
|
2 |
26 Feb 07 |
jari |
55 |
private JCheckBox validationCheckBox; |
2 |
26 Feb 07 |
jari |
56 |
private JRadioButton A0button; |
2 |
26 Feb 07 |
jari |
57 |
private JRadioButton A1button; |
2 |
26 Feb 07 |
jari |
58 |
private JRadioButton A2button; |
2 |
26 Feb 07 |
jari |
59 |
|
2 |
26 Feb 07 |
jari |
60 |
private JRadioButton PDAbutton; |
2 |
26 Feb 07 |
jari |
61 |
private JRadioButton QDAbutton; |
2 |
26 Feb 07 |
jari |
62 |
|
2 |
26 Feb 07 |
jari |
63 |
private JTextField numClassesField; |
2 |
26 Feb 07 |
jari |
64 |
private JTextField kValueField; |
2 |
26 Feb 07 |
jari |
65 |
private JTextField alphaValueField; |
2 |
26 Feb 07 |
jari |
66 |
|
2 |
26 Feb 07 |
jari |
67 |
private ButtonGroup assessSelection; |
2 |
26 Feb 07 |
jari |
68 |
private ButtonGroup classSelection; |
2 |
26 Feb 07 |
jari |
69 |
|
2 |
26 Feb 07 |
jari |
70 |
private JLabel alphaValueLabel; |
2 |
26 Feb 07 |
jari |
71 |
|
2 |
26 Feb 07 |
jari |
72 |
private Listener listener; |
2 |
26 Feb 07 |
jari |
73 |
|
2 |
26 Feb 07 |
jari |
/** Creates new form SVMTrain_ClassifierSelectDialog */ |
2 |
26 Feb 07 |
jari |
75 |
public DAMInitDialog(java.awt.Frame parent, boolean modal) { |
2 |
26 Feb 07 |
jari |
76 |
super(parent, "DAM Initialization" ,modal); |
2 |
26 Feb 07 |
jari |
77 |
listener = new Listener(); |
2 |
26 Feb 07 |
jari |
78 |
|
2 |
26 Feb 07 |
jari |
79 |
initComponents(); |
2 |
26 Feb 07 |
jari |
80 |
okButton.setText("Next"); |
2 |
26 Feb 07 |
jari |
81 |
sampleSelectionPanel.setButtonText("Classify Genes", "Classify Experiments"); |
2 |
26 Feb 07 |
jari |
82 |
sampleSelectionPanel.setClusterGenesSelected(true); |
2 |
26 Feb 07 |
jari |
//sampleSelectionPanel.setClusterSamplesSelected(false); |
2 |
26 Feb 07 |
jari |
84 |
setActionListeners(listener); |
2 |
26 Feb 07 |
jari |
85 |
pack(); |
2 |
26 Feb 07 |
jari |
86 |
setResizable(false); |
2 |
26 Feb 07 |
jari |
87 |
} |
2 |
26 Feb 07 |
jari |
88 |
|
2 |
26 Feb 07 |
jari |
89 |
private void initComponents() { |
2 |
26 Feb 07 |
jari |
90 |
JPanel mainPanel = new JPanel(); |
2 |
26 Feb 07 |
jari |
91 |
mainPanel.setLayout(new java.awt.GridBagLayout()); |
2 |
26 Feb 07 |
jari |
92 |
mainPanel.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
93 |
|
2 |
26 Feb 07 |
jari |
94 |
assessPanel = new JPanel(); |
2 |
26 Feb 07 |
jari |
95 |
paramPanel = new JPanel(); |
2 |
26 Feb 07 |
jari |
96 |
assessSelectionPanel = new JPanel(); |
2 |
26 Feb 07 |
jari |
97 |
|
2 |
26 Feb 07 |
jari |
98 |
A0button = new JRadioButton(); |
2 |
26 Feb 07 |
jari |
99 |
A1button = new JRadioButton(); |
2 |
26 Feb 07 |
jari |
100 |
A2button = new JRadioButton(); |
2 |
26 Feb 07 |
jari |
// NEW 06-16-2004 |
2 |
26 Feb 07 |
jari |
102 |
|
2 |
26 Feb 07 |
jari |
103 |
GridBagConstraints gbc1; |
2 |
26 Feb 07 |
jari |
104 |
|
2 |
26 Feb 07 |
jari |
105 |
setBackground(Color.lightGray); |
2 |
26 Feb 07 |
jari |
106 |
addWindowListener(new WindowAdapter() { |
2 |
26 Feb 07 |
jari |
107 |
public void windowClosing(WindowEvent evt) { |
2 |
26 Feb 07 |
jari |
108 |
closeDialog(evt); |
2 |
26 Feb 07 |
jari |
109 |
} |
2 |
26 Feb 07 |
jari |
110 |
}); |
2 |
26 Feb 07 |
jari |
111 |
|
2 |
26 Feb 07 |
jari |
112 |
sampleSelectionPanel = new SampleSelectionPanel(Color.white, UIManager.getColor("Label.foreground"),true,"Classification Selection"); |
2 |
26 Feb 07 |
jari |
113 |
|
2 |
26 Feb 07 |
jari |
114 |
gbc1 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
115 |
gbc1.gridx = 0; |
2 |
26 Feb 07 |
jari |
116 |
gbc1.gridy = 0; |
2 |
26 Feb 07 |
jari |
117 |
gbc1.weightx = 1; |
2 |
26 Feb 07 |
jari |
118 |
gbc1.fill = java.awt.GridBagConstraints.HORIZONTAL; |
2 |
26 Feb 07 |
jari |
119 |
gbc1.insets = new java.awt.Insets(4, 0, 0, 0); |
2 |
26 Feb 07 |
jari |
120 |
mainPanel.add(sampleSelectionPanel, gbc1); |
2 |
26 Feb 07 |
jari |
121 |
|
2 |
26 Feb 07 |
jari |
122 |
/*****/ |
2 |
26 Feb 07 |
jari |
123 |
processPanel = new JPanel(new GridBagLayout()); |
2 |
26 Feb 07 |
jari |
124 |
processPanel.setBorder(new javax.swing.border.TitledBorder(new EtchedBorder(EtchedBorder.RAISED), "Data Screening", TitledBorder.DEFAULT_JUSTIFICATION, TitledBorder.DEFAULT_POSITION, new Font("Dialog", Font.BOLD, 12), Color.black)); |
2 |
26 Feb 07 |
jari |
125 |
processPanel.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
126 |
java.awt.GridBagConstraints gbc5; |
2 |
26 Feb 07 |
jari |
127 |
|
2 |
26 Feb 07 |
jari |
128 |
|
2 |
26 Feb 07 |
jari |
129 |
|
2 |
26 Feb 07 |
jari |
130 |
geneScreenBox = new JCheckBox("Enable Data Screening Step (ANOVA)", true); |
2 |
26 Feb 07 |
jari |
131 |
geneScreenBox.setHorizontalAlignment(JCheckBox.CENTER); |
2 |
26 Feb 07 |
jari |
132 |
geneScreenBox.setFocusPainted(false); |
2 |
26 Feb 07 |
jari |
133 |
geneScreenBox.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
134 |
geneScreenBox.setForeground(UIManager.getColor("Label.foreground")); |
2 |
26 Feb 07 |
jari |
135 |
geneScreenBox.setActionCommand("screen-data-command"); |
2 |
26 Feb 07 |
jari |
136 |
geneScreenBox.addActionListener(listener); |
2 |
26 Feb 07 |
jari |
137 |
gbc5 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
138 |
gbc5.gridx = 0; |
2 |
26 Feb 07 |
jari |
139 |
gbc5.gridy = 0; |
2 |
26 Feb 07 |
jari |
140 |
gbc5.insets = new java.awt.Insets(0, 0, 10, 0); |
2 |
26 Feb 07 |
jari |
141 |
gbc5.fill = GridBagConstraints.BOTH; |
2 |
26 Feb 07 |
jari |
142 |
gbc5.gridwidth = 2; |
2 |
26 Feb 07 |
jari |
143 |
gbc5.weightx = 1.0; |
2 |
26 Feb 07 |
jari |
144 |
processPanel.add(geneScreenBox, gbc5); |
2 |
26 Feb 07 |
jari |
145 |
|
2 |
26 Feb 07 |
jari |
146 |
alphaValueLabel = new JLabel("Alpha Value"); |
2 |
26 Feb 07 |
jari |
147 |
alphaValueLabel.setHorizontalAlignment(JLabel.RIGHT); |
2 |
26 Feb 07 |
jari |
148 |
gbc5 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
149 |
gbc5.gridx = 0; |
2 |
26 Feb 07 |
jari |
150 |
gbc5.gridy = 1; |
2 |
26 Feb 07 |
jari |
151 |
gbc5.fill = GridBagConstraints.BOTH; |
2 |
26 Feb 07 |
jari |
152 |
gbc5.insets = new java.awt.Insets(0, 0, 10, 0); |
2 |
26 Feb 07 |
jari |
153 |
gbc5.weightx = 1.0; |
2 |
26 Feb 07 |
jari |
154 |
processPanel.add(alphaValueLabel, gbc5); |
2 |
26 Feb 07 |
jari |
155 |
|
2 |
26 Feb 07 |
jari |
156 |
alphaValueField = new JTextField("0.05", 8); |
2 |
26 Feb 07 |
jari |
157 |
alphaValueField.setHorizontalAlignment(JLabel.LEFT); |
2 |
26 Feb 07 |
jari |
158 |
gbc5 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
159 |
gbc5.gridx = 1; |
2 |
26 Feb 07 |
jari |
160 |
gbc5.gridy = 1; |
2 |
26 Feb 07 |
jari |
161 |
gbc5.insets = new java.awt.Insets(0, 0, 10, 40); |
2 |
26 Feb 07 |
jari |
162 |
gbc5.weightx = 1.0; |
2 |
26 Feb 07 |
jari |
163 |
processPanel.add(alphaValueField, gbc5); |
2 |
26 Feb 07 |
jari |
164 |
|
2 |
26 Feb 07 |
jari |
165 |
|
2 |
26 Feb 07 |
jari |
166 |
gbc1 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
167 |
gbc1.gridx = 0; |
2 |
26 Feb 07 |
jari |
168 |
gbc1.gridy = 1; |
2 |
26 Feb 07 |
jari |
169 |
gbc1.fill = GridBagConstraints.HORIZONTAL; |
2 |
26 Feb 07 |
jari |
170 |
mainPanel.add(processPanel, gbc1); |
2 |
26 Feb 07 |
jari |
171 |
|
2 |
26 Feb 07 |
jari |
172 |
/****/ |
2 |
26 Feb 07 |
jari |
173 |
|
2 |
26 Feb 07 |
jari |
174 |
classSelection = new ButtonGroup(); |
2 |
26 Feb 07 |
jari |
175 |
classPanel = new JPanel(); |
2 |
26 Feb 07 |
jari |
176 |
PDAbutton = new JRadioButton(); |
2 |
26 Feb 07 |
jari |
177 |
QDAbutton = new JRadioButton(); |
2 |
26 Feb 07 |
jari |
178 |
classPanel.setLayout(new java.awt.GridBagLayout()); |
2 |
26 Feb 07 |
jari |
179 |
java.awt.GridBagConstraints gbc3; |
2 |
26 Feb 07 |
jari |
180 |
|
2 |
26 Feb 07 |
jari |
181 |
classPanel.setBorder(new javax.swing.border.TitledBorder(new EtchedBorder(EtchedBorder.RAISED), "Classification Algorithm Selection", TitledBorder.DEFAULT_JUSTIFICATION, TitledBorder.DEFAULT_POSITION, new Font("Dialog", Font.BOLD, 12), Color.black)); |
2 |
26 Feb 07 |
jari |
182 |
classPanel.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
183 |
PDAbutton.setToolTipText("Polychotomous Discrimination Algorithm"); |
2 |
26 Feb 07 |
jari |
184 |
PDAbutton.setSelected(true); |
2 |
26 Feb 07 |
jari |
185 |
PDAbutton.setText("PDA"); |
2 |
26 Feb 07 |
jari |
186 |
PDAbutton.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
187 |
PDAbutton.setHorizontalAlignment(JRadioButton.CENTER); |
2 |
26 Feb 07 |
jari |
188 |
classSelection.add(PDAbutton); |
2 |
26 Feb 07 |
jari |
189 |
PDAbutton.setForeground(UIManager.getColor("Label.foreground")); |
2 |
26 Feb 07 |
jari |
190 |
PDAbutton.setFocusPainted(false); |
2 |
26 Feb 07 |
jari |
191 |
|
2 |
26 Feb 07 |
jari |
192 |
gbc3 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
193 |
gbc3.gridx = 0; |
2 |
26 Feb 07 |
jari |
194 |
gbc3.gridy = 0; |
2 |
26 Feb 07 |
jari |
195 |
gbc3.fill = GridBagConstraints.BOTH; |
2 |
26 Feb 07 |
jari |
196 |
gbc3.insets = new java.awt.Insets(10, 0, 10, 0); |
2 |
26 Feb 07 |
jari |
197 |
gbc3.weightx = 1.0; |
2 |
26 Feb 07 |
jari |
198 |
classPanel.add(PDAbutton, gbc3); |
2 |
26 Feb 07 |
jari |
199 |
|
2 |
26 Feb 07 |
jari |
200 |
QDAbutton.setToolTipText("Quadratic Discriminant Analysis Algorithm"); |
2 |
26 Feb 07 |
jari |
201 |
QDAbutton.setText("QDA"); |
2 |
26 Feb 07 |
jari |
202 |
QDAbutton.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
203 |
QDAbutton.setForeground(UIManager.getColor("Label.foreground")); |
2 |
26 Feb 07 |
jari |
204 |
QDAbutton.setHorizontalAlignment(JRadioButton.CENTER); |
2 |
26 Feb 07 |
jari |
205 |
classSelection.add(QDAbutton); |
2 |
26 Feb 07 |
jari |
206 |
QDAbutton.setFocusPainted(false); |
2 |
26 Feb 07 |
jari |
207 |
gbc3 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
208 |
gbc3.gridx = 1; |
2 |
26 Feb 07 |
jari |
209 |
gbc3.gridy = 0; |
2 |
26 Feb 07 |
jari |
210 |
gbc3.fill = GridBagConstraints.BOTH; |
2 |
26 Feb 07 |
jari |
211 |
gbc3.insets = new java.awt.Insets(10, 0, 10, 0); |
2 |
26 Feb 07 |
jari |
212 |
gbc3.weightx = 1.0; |
2 |
26 Feb 07 |
jari |
213 |
classPanel.add(QDAbutton, gbc3); |
2 |
26 Feb 07 |
jari |
214 |
|
2 |
26 Feb 07 |
jari |
215 |
gbc1 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
216 |
gbc1.gridx = 0; |
2 |
26 Feb 07 |
jari |
217 |
gbc1.gridy = 2; |
2 |
26 Feb 07 |
jari |
218 |
gbc1.fill = GridBagConstraints.HORIZONTAL; |
2 |
26 Feb 07 |
jari |
219 |
mainPanel.add(classPanel, gbc1); |
2 |
26 Feb 07 |
jari |
220 |
|
2 |
26 Feb 07 |
jari |
221 |
/******/ |
2 |
26 Feb 07 |
jari |
222 |
|
2 |
26 Feb 07 |
jari |
223 |
paramPanel.setLayout(new java.awt.GridBagLayout()); |
2 |
26 Feb 07 |
jari |
224 |
paramPanel.setBorder(new javax.swing.border.TitledBorder(new EtchedBorder(EtchedBorder.RAISED), "DAM Classification Parameters", TitledBorder.DEFAULT_JUSTIFICATION, TitledBorder.DEFAULT_POSITION, new Font("Dialog", Font.BOLD, 12), Color.black)); |
2 |
26 Feb 07 |
jari |
225 |
paramPanel.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
226 |
java.awt.GridBagConstraints gbc4; |
2 |
26 Feb 07 |
jari |
227 |
|
2 |
26 Feb 07 |
jari |
228 |
JLabel numClassesLabel = new JLabel("Number of Classes"); |
2 |
26 Feb 07 |
jari |
229 |
numClassesLabel.setHorizontalAlignment(JLabel.RIGHT); |
2 |
26 Feb 07 |
jari |
230 |
paramPanel.add(numClassesLabel); |
2 |
26 Feb 07 |
jari |
231 |
gbc4 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
232 |
gbc4.gridx = 0; |
2 |
26 Feb 07 |
jari |
233 |
gbc4.gridy = 0; |
2 |
26 Feb 07 |
jari |
234 |
gbc4.fill = GridBagConstraints.BOTH; |
2 |
26 Feb 07 |
jari |
235 |
gbc4.insets = new java.awt.Insets(0, 0, 0, 0); |
2 |
26 Feb 07 |
jari |
236 |
gbc4.weightx = 1.0; |
2 |
26 Feb 07 |
jari |
237 |
paramPanel.add(numClassesLabel, gbc4); |
2 |
26 Feb 07 |
jari |
238 |
|
2 |
26 Feb 07 |
jari |
239 |
numClassesField = new JTextField("3", 8); |
2 |
26 Feb 07 |
jari |
240 |
paramPanel.add(numClassesField); |
2 |
26 Feb 07 |
jari |
241 |
gbc4 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
242 |
gbc4.gridx = 1; |
2 |
26 Feb 07 |
jari |
243 |
gbc4.gridy = 0; |
2 |
26 Feb 07 |
jari |
244 |
gbc4.insets = new java.awt.Insets(0, 0, 0, 40); |
2 |
26 Feb 07 |
jari |
245 |
gbc4.weightx = 1.0; |
2 |
26 Feb 07 |
jari |
246 |
paramPanel.add(numClassesField, gbc4); |
2 |
26 Feb 07 |
jari |
247 |
|
2 |
26 Feb 07 |
jari |
248 |
JLabel kValueLabel = new JLabel("Number Of Components"); |
2 |
26 Feb 07 |
jari |
249 |
kValueLabel.setHorizontalAlignment(JLabel.RIGHT); |
2 |
26 Feb 07 |
jari |
250 |
gbc4 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
251 |
gbc4.gridx = 0; |
2 |
26 Feb 07 |
jari |
252 |
gbc4.gridy = 1; |
2 |
26 Feb 07 |
jari |
253 |
gbc4.fill = GridBagConstraints.BOTH; |
2 |
26 Feb 07 |
jari |
254 |
gbc4.insets = new java.awt.Insets(10, 0, 10, 0); |
2 |
26 Feb 07 |
jari |
255 |
gbc4.weightx = 1.0; |
2 |
26 Feb 07 |
jari |
256 |
paramPanel.add(kValueLabel, gbc4); |
2 |
26 Feb 07 |
jari |
257 |
|
2 |
26 Feb 07 |
jari |
258 |
kValueField = new JTextField("3", 8); |
2 |
26 Feb 07 |
jari |
259 |
kValueField.setHorizontalAlignment(JTextField.LEFT); |
2 |
26 Feb 07 |
jari |
260 |
gbc4 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
261 |
gbc4.gridx = 1; |
2 |
26 Feb 07 |
jari |
262 |
gbc4.gridy = 1; |
2 |
26 Feb 07 |
jari |
263 |
gbc4.insets = new java.awt.Insets(10, 0, 10, 40); |
2 |
26 Feb 07 |
jari |
264 |
gbc4.weightx = 1.0; |
2 |
26 Feb 07 |
jari |
265 |
paramPanel.add(kValueField, gbc4); |
2 |
26 Feb 07 |
jari |
266 |
|
2 |
26 Feb 07 |
jari |
267 |
gbc1 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
268 |
gbc1.gridx = 0; |
2 |
26 Feb 07 |
jari |
269 |
gbc1.gridy = 3; |
2 |
26 Feb 07 |
jari |
270 |
gbc1.fill = GridBagConstraints.HORIZONTAL; |
2 |
26 Feb 07 |
jari |
271 |
mainPanel.add(paramPanel, gbc1); |
2 |
26 Feb 07 |
jari |
272 |
|
2 |
26 Feb 07 |
jari |
273 |
/*****/ |
2 |
26 Feb 07 |
jari |
274 |
assessSelection = new ButtonGroup(); |
2 |
26 Feb 07 |
jari |
275 |
|
2 |
26 Feb 07 |
jari |
276 |
assessSelectionPanel.setLayout(new java.awt.GridBagLayout()); |
2 |
26 Feb 07 |
jari |
277 |
java.awt.GridBagConstraints gbc2; |
2 |
26 Feb 07 |
jari |
278 |
|
2 |
26 Feb 07 |
jari |
279 |
assessSelectionPanel.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
280 |
|
2 |
26 Feb 07 |
jari |
// NEW 06-16-2004 |
2 |
26 Feb 07 |
jari |
282 |
|
2 |
26 Feb 07 |
jari |
/* A3button.setToolTipText("Initial Classification"); |
2 |
26 Feb 07 |
jari |
A3button.setSelected(true); |
2 |
26 Feb 07 |
jari |
A3button.setText("Initial Classification"); |
2 |
26 Feb 07 |
jari |
A3button.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
assessSelection.add(A3button); |
2 |
26 Feb 07 |
jari |
A3button.setForeground(UIManager.getColor("Label.foreground")); |
2 |
26 Feb 07 |
jari |
A3button.setFocusPainted(false); |
2 |
26 Feb 07 |
jari |
gbc2 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
gbc2.gridx = 0; |
2 |
26 Feb 07 |
jari |
gbc2.gridy = 1; |
2 |
26 Feb 07 |
jari |
gbc2.fill = GridBagConstraints.BOTH; |
2 |
26 Feb 07 |
jari |
gbc2.insets = new java.awt.Insets(0, 40, 0, 0); |
2 |
26 Feb 07 |
jari |
gbc2.gridwidth = 1; |
2 |
26 Feb 07 |
jari |
gbc2.gridheight = 1; |
2 |
26 Feb 07 |
jari |
gbc2.weightx = 1.0; |
2 |
26 Feb 07 |
jari |
298 |
*/ |
2 |
26 Feb 07 |
jari |
299 |
|
2 |
26 Feb 07 |
jari |
300 |
validationCheckBox = new JCheckBox("Enable Validation", false); |
2 |
26 Feb 07 |
jari |
301 |
validationCheckBox.setOpaque(true); |
2 |
26 Feb 07 |
jari |
302 |
validationCheckBox.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
303 |
validationCheckBox.setFocusPainted(false); |
2 |
26 Feb 07 |
jari |
304 |
validationCheckBox.setHorizontalAlignment(JCheckBox.CENTER); |
2 |
26 Feb 07 |
jari |
305 |
validationCheckBox.setActionCommand("validation-command"); |
2 |
26 Feb 07 |
jari |
306 |
validationCheckBox.addActionListener(listener); |
2 |
26 Feb 07 |
jari |
307 |
assessSelectionPanel.add(validationCheckBox, new GridBagConstraints(0,0,3,1, 1, 1, GridBagConstraints.CENTER, GridBagConstraints.BOTH, new Insets(5,0,5,0), 0, 0)); |
2 |
26 Feb 07 |
jari |
308 |
|
2 |
26 Feb 07 |
jari |
309 |
|
2 |
26 Feb 07 |
jari |
310 |
|
2 |
26 Feb 07 |
jari |
// assessSelectionPanel.add(A3button, gbc2); |
2 |
26 Feb 07 |
jari |
312 |
|
2 |
26 Feb 07 |
jari |
313 |
A0button.setToolTipText("A0 Assessment Algorithm"); |
2 |
26 Feb 07 |
jari |
314 |
A0button.setSelected(true); |
2 |
26 Feb 07 |
jari |
315 |
A0button.setEnabled(false); |
2 |
26 Feb 07 |
jari |
316 |
A0button.setText("A0"); |
2 |
26 Feb 07 |
jari |
317 |
A0button.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
318 |
assessSelection.add(A0button); |
2 |
26 Feb 07 |
jari |
319 |
A0button.setForeground(UIManager.getColor("Label.foreground")); |
2 |
26 Feb 07 |
jari |
320 |
A0button.setFocusPainted(false); |
2 |
26 Feb 07 |
jari |
321 |
gbc2 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
322 |
gbc2.gridx = 0; |
2 |
26 Feb 07 |
jari |
323 |
gbc2.gridy = 1; |
2 |
26 Feb 07 |
jari |
324 |
gbc2.fill = GridBagConstraints.BOTH; |
2 |
26 Feb 07 |
jari |
325 |
gbc2.insets = new java.awt.Insets(0, 40, 10, 0); |
2 |
26 Feb 07 |
jari |
326 |
gbc2.gridwidth = 1; |
2 |
26 Feb 07 |
jari |
327 |
gbc2.gridheight = 1; |
2 |
26 Feb 07 |
jari |
328 |
gbc2.weightx = 1.0; |
2 |
26 Feb 07 |
jari |
329 |
|
2 |
26 Feb 07 |
jari |
330 |
assessSelectionPanel.add(A0button, gbc2); |
2 |
26 Feb 07 |
jari |
331 |
|
2 |
26 Feb 07 |
jari |
332 |
A1button.setToolTipText("A1 Assessment Algorithm"); |
2 |
26 Feb 07 |
jari |
333 |
A1button.setText("A1"); |
2 |
26 Feb 07 |
jari |
334 |
A1button.setEnabled(false); |
2 |
26 Feb 07 |
jari |
335 |
A1button.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
336 |
assessSelection.add(A1button); |
2 |
26 Feb 07 |
jari |
337 |
A1button.setForeground(UIManager.getColor("Label.foreground")); |
2 |
26 Feb 07 |
jari |
338 |
A1button.setFocusPainted(false); |
2 |
26 Feb 07 |
jari |
339 |
gbc2 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
340 |
gbc2.gridx = 1; |
2 |
26 Feb 07 |
jari |
341 |
gbc2.gridy = 1; |
2 |
26 Feb 07 |
jari |
342 |
gbc2.fill = GridBagConstraints.BOTH; |
2 |
26 Feb 07 |
jari |
343 |
gbc2.insets = new java.awt.Insets(0, 30, 10, 0); |
2 |
26 Feb 07 |
jari |
344 |
gbc2.gridwidth = 1; |
2 |
26 Feb 07 |
jari |
345 |
gbc2.gridheight = 1; |
2 |
26 Feb 07 |
jari |
346 |
gbc2.weightx = 1.0; |
2 |
26 Feb 07 |
jari |
347 |
|
2 |
26 Feb 07 |
jari |
348 |
assessSelectionPanel.add(A1button, gbc2); |
2 |
26 Feb 07 |
jari |
349 |
|
2 |
26 Feb 07 |
jari |
350 |
A2button.setToolTipText("A2 Assessment Algorithm"); |
2 |
26 Feb 07 |
jari |
351 |
A2button.setText("A2"); |
2 |
26 Feb 07 |
jari |
352 |
A2button.setEnabled(false); |
2 |
26 Feb 07 |
jari |
353 |
A2button.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
354 |
assessSelection.add(A2button); |
2 |
26 Feb 07 |
jari |
355 |
A2button.setForeground(UIManager.getColor("Label.foreground")); |
2 |
26 Feb 07 |
jari |
356 |
A2button.setFocusPainted(false); |
2 |
26 Feb 07 |
jari |
357 |
gbc2 = new GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
358 |
gbc2.gridx = 2; |
2 |
26 Feb 07 |
jari |
359 |
gbc2.gridy = 1; |
2 |
26 Feb 07 |
jari |
360 |
gbc2.fill = GridBagConstraints.BOTH; |
2 |
26 Feb 07 |
jari |
361 |
gbc2.insets = new java.awt.Insets(0, 30, 10, 0); |
2 |
26 Feb 07 |
jari |
362 |
gbc2.gridwidth = 1; |
2 |
26 Feb 07 |
jari |
363 |
gbc2.gridheight = 1; |
2 |
26 Feb 07 |
jari |
364 |
gbc2.weightx = 1.0; |
2 |
26 Feb 07 |
jari |
365 |
|
2 |
26 Feb 07 |
jari |
366 |
assessSelectionPanel.add(A2button, gbc2); |
2 |
26 Feb 07 |
jari |
367 |
|
2 |
26 Feb 07 |
jari |
368 |
|
2 |
26 Feb 07 |
jari |
369 |
assessPanel.setLayout(new java.awt.GridBagLayout()); |
2 |
26 Feb 07 |
jari |
370 |
java.awt.GridBagConstraints gbc6; |
2 |
26 Feb 07 |
jari |
371 |
|
2 |
26 Feb 07 |
jari |
372 |
assessPanel.setBorder(new javax.swing.border.TitledBorder(new EtchedBorder(EtchedBorder.RAISED), "Validation Selection", TitledBorder.DEFAULT_JUSTIFICATION, TitledBorder.DEFAULT_POSITION, new Font("Dialog", Font.BOLD, 12), Color.black)); |
2 |
26 Feb 07 |
jari |
373 |
assessPanel.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
374 |
|
2 |
26 Feb 07 |
jari |
375 |
assessSelectionPanel.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
376 |
assessSelectionPanel.setForeground(UIManager.getColor("Label.foreground")); |
2 |
26 Feb 07 |
jari |
377 |
gbc6 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
378 |
gbc6.gridx = 0; |
2 |
26 Feb 07 |
jari |
379 |
gbc6.gridy = 0; |
2 |
26 Feb 07 |
jari |
380 |
gbc6.fill = GridBagConstraints.BOTH; |
2 |
26 Feb 07 |
jari |
381 |
gbc6.weightx = 1.0; |
2 |
26 Feb 07 |
jari |
382 |
|
2 |
26 Feb 07 |
jari |
383 |
assessPanel.add(assessSelectionPanel, gbc6); |
2 |
26 Feb 07 |
jari |
384 |
|
2 |
26 Feb 07 |
jari |
385 |
/* |
2 |
26 Feb 07 |
jari |
skipCrossValBox = new JCheckBox("Skip Cross Validation step (LOOCV)"); |
2 |
26 Feb 07 |
jari |
skipCrossValBox.setFocusPainted(false); |
2 |
26 Feb 07 |
jari |
skipCrossValBox.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
skipCrossValBox.setForeground(UIManager.getColor("Label.foreground")); |
2 |
26 Feb 07 |
jari |
skipCrossValBox.setHorizontalAlignment(javax.swing.SwingConstants.LEFT); |
2 |
26 Feb 07 |
jari |
391 |
|
2 |
26 Feb 07 |
jari |
gbc6 = new GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
gbc6.gridx = 0; |
2 |
26 Feb 07 |
jari |
gbc6.gridy = 1; |
2 |
26 Feb 07 |
jari |
gbc6.fill = GridBagConstraints.BOTH; |
2 |
26 Feb 07 |
jari |
gbc6.insets = new java.awt.Insets(0, 40, 0, 0); |
2 |
26 Feb 07 |
jari |
gbc6.weightx = 1.0; |
2 |
26 Feb 07 |
jari |
assessPanel.add(skipCrossValBox, gbc6); |
2 |
26 Feb 07 |
jari |
399 |
*/ |
2 |
26 Feb 07 |
jari |
400 |
|
2 |
26 Feb 07 |
jari |
401 |
gbc1 = new java.awt.GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
402 |
gbc1.gridx = 0; |
2 |
26 Feb 07 |
jari |
403 |
gbc1.gridy = 4; |
2 |
26 Feb 07 |
jari |
404 |
gbc1.fill = GridBagConstraints.HORIZONTAL; |
2 |
26 Feb 07 |
jari |
405 |
mainPanel.add(assessPanel, gbc1); |
2 |
26 Feb 07 |
jari |
406 |
|
2 |
26 Feb 07 |
jari |
407 |
addContent(mainPanel); |
2 |
26 Feb 07 |
jari |
408 |
} |
2 |
26 Feb 07 |
jari |
409 |
|
2 |
26 Feb 07 |
jari |
/** Closes the dialog */ |
2 |
26 Feb 07 |
jari |
411 |
private void closeDialog(WindowEvent evt) { |
2 |
26 Feb 07 |
jari |
412 |
setVisible(false); |
2 |
26 Feb 07 |
jari |
413 |
dispose(); |
2 |
26 Feb 07 |
jari |
414 |
} |
2 |
26 Feb 07 |
jari |
415 |
|
2 |
26 Feb 07 |
jari |
416 |
/** |
2 |
26 Feb 07 |
jari |
* Returns true if gene DAM's are to be evaluated |
2 |
26 Feb 07 |
jari |
418 |
*/ |
2 |
26 Feb 07 |
jari |
419 |
public boolean isEvaluateGenesSelected(){ |
2 |
26 Feb 07 |
jari |
420 |
return sampleSelectionPanel.isClusterGenesSelected(); |
2 |
26 Feb 07 |
jari |
421 |
} |
2 |
26 Feb 07 |
jari |
422 |
|
2 |
26 Feb 07 |
jari |
423 |
/** |
2 |
26 Feb 07 |
jari |
* Returns a constant indicating which SVM process to run |
2 |
26 Feb 07 |
jari |
* Train and classify, train only, classify only |
2 |
26 Feb 07 |
jari |
426 |
*/ |
2 |
26 Feb 07 |
jari |
427 |
public int getAssessmentSelection(){ |
2 |
26 Feb 07 |
jari |
//if validation is not selected return A3 indicating only initial classification |
2 |
26 Feb 07 |
jari |
429 |
if(!this.validationCheckBox.isSelected()) |
2 |
26 Feb 07 |
jari |
430 |
return DAMGUI.A3; |
2 |
26 Feb 07 |
jari |
431 |
|
2 |
26 Feb 07 |
jari |
432 |
if(this.A2button.isSelected()) |
2 |
26 Feb 07 |
jari |
433 |
return DAMGUI.A2; |
2 |
26 Feb 07 |
jari |
434 |
else if(this.A1button.isSelected()) |
2 |
26 Feb 07 |
jari |
435 |
return DAMGUI.A1; |
2 |
26 Feb 07 |
jari |
436 |
else if (this.A0button.isSelected()) |
2 |
26 Feb 07 |
jari |
437 |
return DAMGUI.A0; |
2 |
26 Feb 07 |
jari |
438 |
else |
2 |
26 Feb 07 |
jari |
439 |
return DAMGUI.A3; |
2 |
26 Feb 07 |
jari |
440 |
} |
2 |
26 Feb 07 |
jari |
441 |
|
2 |
26 Feb 07 |
jari |
442 |
|
2 |
26 Feb 07 |
jari |
443 |
/** |
2 |
26 Feb 07 |
jari |
444 |
*/ |
2 |
26 Feb 07 |
jari |
445 |
public boolean isPDASelected(){ |
2 |
26 Feb 07 |
jari |
446 |
if (this.PDAbutton.isSelected()) |
2 |
26 Feb 07 |
jari |
447 |
return true; |
2 |
26 Feb 07 |
jari |
448 |
else |
2 |
26 Feb 07 |
jari |
449 |
return false; |
2 |
26 Feb 07 |
jari |
450 |
} |
2 |
26 Feb 07 |
jari |
451 |
|
2 |
26 Feb 07 |
jari |
452 |
public int getNumClasses() { |
2 |
26 Feb 07 |
jari |
453 |
String s = numClassesField.getText(); |
2 |
26 Feb 07 |
jari |
454 |
return Integer.parseInt(s); |
2 |
26 Feb 07 |
jari |
455 |
} |
2 |
26 Feb 07 |
jari |
456 |
|
2 |
26 Feb 07 |
jari |
457 |
public int getKValue() { |
2 |
26 Feb 07 |
jari |
458 |
String s = kValueField.getText(); |
2 |
26 Feb 07 |
jari |
459 |
return Integer.parseInt(s); |
2 |
26 Feb 07 |
jari |
460 |
} |
2 |
26 Feb 07 |
jari |
461 |
|
2 |
26 Feb 07 |
jari |
462 |
public double getAlphaValue() { |
2 |
26 Feb 07 |
jari |
463 |
String s = alphaValueField.getText(); |
2 |
26 Feb 07 |
jari |
464 |
return Double.parseDouble(s); |
2 |
26 Feb 07 |
jari |
465 |
} |
2 |
26 Feb 07 |
jari |
466 |
|
2 |
26 Feb 07 |
jari |
467 |
|
2 |
26 Feb 07 |
jari |
468 |
/** |
2 |
26 Feb 07 |
jari |
* Returns boolean selection for calculating HCL on SVM results |
2 |
26 Feb 07 |
jari |
470 |
*/ |
2 |
26 Feb 07 |
jari |
471 |
/* |
2 |
26 Feb 07 |
jari |
public boolean getHCLSelection(){ |
2 |
26 Feb 07 |
jari |
return hclOpsPanel.isHCLSelected(); |
2 |
26 Feb 07 |
jari |
474 |
} |
2 |
26 Feb 07 |
jari |
475 |
*/ |
2 |
26 Feb 07 |
jari |
476 |
|
2 |
26 Feb 07 |
jari |
477 |
public int showModal() { |
2 |
26 Feb 07 |
jari |
478 |
Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize(); |
2 |
26 Feb 07 |
jari |
479 |
setLocation((screenSize.width - getSize().width)/2, (screenSize.height - getSize().height)/2); |
2 |
26 Feb 07 |
jari |
480 |
show(); |
2 |
26 Feb 07 |
jari |
481 |
return result; |
2 |
26 Feb 07 |
jari |
482 |
} |
2 |
26 Feb 07 |
jari |
483 |
|
2 |
26 Feb 07 |
jari |
484 |
|
2 |
26 Feb 07 |
jari |
485 |
|
2 |
26 Feb 07 |
jari |
486 |
public void resetControls(){ |
2 |
26 Feb 07 |
jari |
487 |
geneScreenBox.setSelected(true); |
2 |
26 Feb 07 |
jari |
488 |
this.alphaValueLabel.setEnabled(true); |
2 |
26 Feb 07 |
jari |
489 |
this.alphaValueField.setEnabled(true); |
2 |
26 Feb 07 |
jari |
490 |
|
2 |
26 Feb 07 |
jari |
491 |
sampleSelectionPanel.setClusterGenesSelected(true); |
2 |
26 Feb 07 |
jari |
492 |
validationCheckBox.setSelected(false); |
2 |
26 Feb 07 |
jari |
493 |
A0button.setEnabled(false); |
2 |
26 Feb 07 |
jari |
494 |
A1button.setEnabled(false); |
2 |
26 Feb 07 |
jari |
495 |
A2button.setEnabled(false); |
2 |
26 Feb 07 |
jari |
496 |
|
2 |
26 Feb 07 |
jari |
497 |
PDAbutton.setSelected(true); |
2 |
26 Feb 07 |
jari |
498 |
numClassesField.setText("3"); |
2 |
26 Feb 07 |
jari |
499 |
kValueField.setText("3"); |
2 |
26 Feb 07 |
jari |
500 |
alphaValueField.setText("0.05"); |
2 |
26 Feb 07 |
jari |
501 |
skipGeneScreeningStep = false; |
2 |
26 Feb 07 |
jari |
502 |
skipCrossValidationStep = false; |
2 |
26 Feb 07 |
jari |
503 |
geneScreenBox.setSelected(true); |
2 |
26 Feb 07 |
jari |
504 |
|
2 |
26 Feb 07 |
jari |
505 |
} |
2 |
26 Feb 07 |
jari |
506 |
|
2 |
26 Feb 07 |
jari |
507 |
/** |
2 |
26 Feb 07 |
jari |
* @param args the command line arguments |
2 |
26 Feb 07 |
jari |
509 |
*/ |
2 |
26 Feb 07 |
jari |
510 |
public static void main(String args[]) { |
2 |
26 Feb 07 |
jari |
511 |
new DAMInitDialog(new javax.swing.JFrame(), true).show(); |
2 |
26 Feb 07 |
jari |
512 |
System.exit(0); |
2 |
26 Feb 07 |
jari |
513 |
} |
2 |
26 Feb 07 |
jari |
514 |
|
2 |
26 Feb 07 |
jari |
515 |
|
2 |
26 Feb 07 |
jari |
516 |
public boolean getSkipGeneSelectionValue() { |
2 |
26 Feb 07 |
jari |
517 |
return !geneScreenBox.isSelected(); |
2 |
26 Feb 07 |
jari |
518 |
} |
2 |
26 Feb 07 |
jari |
519 |
|
2 |
26 Feb 07 |
jari |
520 |
/* |
2 |
26 Feb 07 |
jari |
public boolean getSkipLOOCVValue() { |
2 |
26 Feb 07 |
jari |
return skipCrossValBox.isSelected(); |
2 |
26 Feb 07 |
jari |
523 |
} |
2 |
26 Feb 07 |
jari |
524 |
*/ |
2 |
26 Feb 07 |
jari |
525 |
|
2 |
26 Feb 07 |
jari |
526 |
private class Listener extends DialogListener { |
2 |
26 Feb 07 |
jari |
527 |
|
2 |
26 Feb 07 |
jari |
528 |
public void actionPerformed(ActionEvent e) { |
2 |
26 Feb 07 |
jari |
529 |
String command = e.getActionCommand(); |
2 |
26 Feb 07 |
jari |
530 |
if (command.equals("ok-command")) { |
2 |
26 Feb 07 |
jari |
531 |
result = JOptionPane.OK_OPTION; |
2 |
26 Feb 07 |
jari |
532 |
dispose(); |
2 |
26 Feb 07 |
jari |
533 |
} else if (command.equals("cancel-command")) { |
2 |
26 Feb 07 |
jari |
534 |
result = JOptionPane.CANCEL_OPTION; |
2 |
26 Feb 07 |
jari |
535 |
dispose(); |
2 |
26 Feb 07 |
jari |
536 |
} else if (command.equals("reset-command")){ |
2 |
26 Feb 07 |
jari |
537 |
resetControls(); |
2 |
26 Feb 07 |
jari |
538 |
} else if (command.equals("screen-data-command")) { |
2 |
26 Feb 07 |
jari |
539 |
alphaValueField.setEnabled(geneScreenBox.isSelected()); |
2 |
26 Feb 07 |
jari |
540 |
alphaValueLabel.setEnabled(geneScreenBox.isSelected()); |
2 |
26 Feb 07 |
jari |
541 |
} else if (command.equals("validation-command")) { |
2 |
26 Feb 07 |
jari |
542 |
A0button.setEnabled(validationCheckBox.isSelected()); |
2 |
26 Feb 07 |
jari |
543 |
A1button.setEnabled(validationCheckBox.isSelected()); |
2 |
26 Feb 07 |
jari |
544 |
A2button.setEnabled(validationCheckBox.isSelected()); |
2 |
26 Feb 07 |
jari |
545 |
} else if (command.equals("info-command")){ |
2 |
26 Feb 07 |
jari |
546 |
HelpWindow hw = new HelpWindow(DAMInitDialog.this, "DAM Initialization Dialog"); |
2 |
26 Feb 07 |
jari |
547 |
if(hw.getWindowContent()){ |
2 |
26 Feb 07 |
jari |
548 |
hw.setSize(450,650); |
2 |
26 Feb 07 |
jari |
549 |
hw.setLocation(); |
2 |
26 Feb 07 |
jari |
550 |
hw.show(); |
2 |
26 Feb 07 |
jari |
551 |
} |
2 |
26 Feb 07 |
jari |
552 |
else { |
2 |
26 Feb 07 |
jari |
553 |
hw.setVisible(false); |
2 |
26 Feb 07 |
jari |
554 |
hw.dispose(); |
2 |
26 Feb 07 |
jari |
555 |
} |
2 |
26 Feb 07 |
jari |
556 |
} |
2 |
26 Feb 07 |
jari |
557 |
|
2 |
26 Feb 07 |
jari |
558 |
} |
2 |
26 Feb 07 |
jari |
559 |
|
2 |
26 Feb 07 |
jari |
560 |
public void windowClosing(WindowEvent e) { |
2 |
26 Feb 07 |
jari |
561 |
result = JOptionPane.CLOSED_OPTION; |
2 |
26 Feb 07 |
jari |
562 |
dispose(); |
2 |
26 Feb 07 |
jari |
563 |
} |
2 |
26 Feb 07 |
jari |
564 |
|
2 |
26 Feb 07 |
jari |
565 |
} |
2 |
26 Feb 07 |
jari |
566 |
|
2 |
26 Feb 07 |
jari |
567 |
} |
2 |
26 Feb 07 |
jari |
568 |
|