(User) configCmb.getSelectedItem());
}
});
JLabel outputDirLbl = new JLabel("Input Directory:");
JLabel logDirLbl = new JLabel("Log Directory:");
ImageButton logDirButt = null;
ImageButton inputDirButt = null;
logDirButt = new ImageButton(folder);
inputDirButt = new ImageButton(folder);
logDirButt.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) {
File selected = FileDialog.showSelectDialog(parent, new File(
logDir.getText()).getAbsolutePath());
if ((selected != null) && (selected.isDirectory())) {
logDir.setText(selected.getAbsolutePath());
}
}
});
inputDirButt.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) {
File selected = FileDialog.showSelectDialog(parent, new File(
inputDir.getText()).getAbsolutePath());
if ((selected != null) && (selected.isDirectory())) {
inputDir.setText(selected.getAbsolutePath());
}
}
});
GridBagConstraints gbc = new GridBagConstraints();
gbc.gridx = 0;
gbc.gridy = 0;
gbc.insets = new Insets(5, 5, 5, 5);
gbc.weightx = 0;
optionPnl.add(userLbl, gbc);
gbc.fill = GridBagConstraints.HORIZONTAL;
gbc.weightx = 3;
gbc.gridx = 1;
optionPnl.add(configCmb, gbc);
gbc.gridx = 0;
gbc.gridy = 1;
gbc.anchor = GridBagConstraints.WEST;
gbc.weightx = 0;
optionPnl.add(outputDirLbl, gbc);
gbc.gridx = 1;
gbc.gridy = 1;
gbc.fill = GridBagConstraints.HORIZONTAL;
gbc.weightx = 1;
optionPnl.add(inputDir, gbc);
gbc.gridx = 2;
gbc.gridy = 1;
gbc.fill = GridBagConstraints.NONE;
gbc.weightx = 0;
optionPnl.add(inputDirButt, gbc);
gbc.gridx = 0;
gbc.gridy = 2;
gbc.weightx = 0;
optionPnl.add(logDirLbl, gbc);
gbc.gridx = 1;
gbc.gridy = 2;
gbc.fill = GridBagConstraints.HORIZONTAL;
gbc.weightx = 1;
optionPnl.add(logDir, gbc);
gbc.gridx = 2;
gbc.gridy = 2;
gbc.fill = GridBagConstraints.NONE;
gbc.weightx = 0;
optionPnl.add(logDirButt, gbc);
JLabel oldPasswordLbl = new JLabel("Old Password:");
JLabel newPasswordLbl = new JLabel("New Password:");
JLabel confirmPasswordLbl = new JLabel("Confirm Password:");
final JPasswordField oldPasswordTxt = new JPasswordField();
final JPasswordField newPasswordTxt = new JPasswordField();
final JPasswordField confirmPasswordTxt = new JPasswordField();
ImageButton changeBtn = new ImageButton("Change Password!",
passwordButtonIcon);
// GridBagConstraints pgbc = new GridBagConstraints();
// pgbc.gridx = 0;
// pgbc.gridy = 0;
// pgbc.insets = new Insets(5,5,5,5);
// pgbc.weightx = 0;
// passwordPnl.add(oldPasswordLbl,pgbc);
// pgbc.gridx = 1;
// pgbc.weightx = 3;
// pgbc.fill = GridBagConstraints.HORIZONTAL;
// passwordPnl.add(oldPasswordTxt,pgbc);
// pgbc.gridx = 0;
// pgbc.gridy = 1;
// pgbc.weightx = 0;
// pgbc.fill = GridBagConstraints.NONE;
// passwordPnl.add(newPasswordLbl,pgbc);
// pgbc.gridx = 1;
// pgbc.weightx = 3;
// pgbc.fill = GridBagConstraints.HORIZONTAL;
// passwordPnl.add(newPasswordTxt,pgbc);
// pgbc.gridx = 0;
// pgbc.gridy = 2;
// pgbc.weightx = 0;
// pgbc.fill = GridBagConstraints.NONE;
// passwordPnl.add(confirmPasswordLbl,pgbc);
// pgbc.gridx = 1;
// pgbc.weightx = 3;
// pgbc.fill = GridBagConstraints.HORIZONTAL;
// passwordPnl.add(confirmPasswordTxt,pgbc);
// pgbc.gridx = 2;
// pgbc.gridy = 2;
// pgbc.weightx = 0;
// pgbc.fill = GridBagConstraints.NONE;
// passwordPnl.add(changeBtn,pgbc);
changeBtn.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent ae) {
String oldPassword = new String(oldPasswordTxt.getPassword());
String newPassword = new String(newPasswordTxt.getPassword());
String confirmPassword = new String(confirmPasswordTxt
.getPassword());