|
|
|
@ -150,7 +150,7 @@ public class NumberEditorValidatePane extends JPanel {
|
|
|
|
|
setMaxListener = new ActionListener() { |
|
|
|
|
@Override |
|
|
|
|
public void actionPerformed(ActionEvent e) { |
|
|
|
|
errorMsgTextFieldPane.setVisible(setMaxValueCheckBox.isSelected() || setMinValueCheckBox.isSelected()); |
|
|
|
|
refreshErrorMsgTip(); |
|
|
|
|
if (setMaxValueCheckBox.isSelected()) { |
|
|
|
|
maxValueSpinner.setEnabled(true); |
|
|
|
|
Double value = (double) 0; |
|
|
|
@ -172,7 +172,7 @@ public class NumberEditorValidatePane extends JPanel {
|
|
|
|
|
setMinListener = new ActionListener() { |
|
|
|
|
@Override |
|
|
|
|
public void actionPerformed(ActionEvent e) { |
|
|
|
|
errorMsgTextFieldPane.setVisible(setMaxValueCheckBox.isSelected() || setMinValueCheckBox.isSelected()); |
|
|
|
|
refreshErrorMsgTip(); |
|
|
|
|
if (setMinValueCheckBox.isSelected()) { |
|
|
|
|
minValueSpinner.setEnabled(true); |
|
|
|
|
Double value = (double) 0; |
|
|
|
@ -220,6 +220,14 @@ public class NumberEditorValidatePane extends JPanel {
|
|
|
|
|
}; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private void refreshErrorMsgTip() { |
|
|
|
|
boolean visible = setMaxValueCheckBox.isSelected() || setMinValueCheckBox.isSelected(); |
|
|
|
|
errorMsgTextFieldPane.setVisible(visible); |
|
|
|
|
if (!visible) { |
|
|
|
|
errorMsgTextField.setText(StringUtils.EMPTY); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public void populate(NumberEditor e) { |
|
|
|
|
allowDecimalsCheckBox.setSelected(e.isAllowDecimals()); |
|
|
|
|
if (e.isAllowDecimals()) { |
|
|
|
|