Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHenrik Rentz-Reichert2011-03-09 10:33:11 +0000
committerHenrik Rentz-Reichert2011-03-09 10:33:11 +0000
commit23b59ffc67a42109153d2d21c1c21bdb3aaaf2e5 (patch)
treecfdc6aa0b7631ebb6e4f4a8783066bf4406caf0d
parentfd44722f66e840cc9f0d146884d76b2ba8875724 (diff)
downloadorg.eclipse.etrice-23b59ffc67a42109153d2d21c1c21bdb3aaaf2e5.tar.gz
org.eclipse.etrice-23b59ffc67a42109153d2d21c1c21bdb3aaaf2e5.tar.xz
org.eclipse.etrice-23b59ffc67a42109153d2d21c1c21bdb3aaaf2e5.zip
common.ui: ok button enabled if initially valid
-rw-r--r--plugins/org.eclipse.etrice.ui.common/src/org/eclipse/etrice/ui/common/dialogs/AbstractPropertyDialog.java9
1 files changed, 4 insertions, 5 deletions
diff --git a/plugins/org.eclipse.etrice.ui.common/src/org/eclipse/etrice/ui/common/dialogs/AbstractPropertyDialog.java b/plugins/org.eclipse.etrice.ui.common/src/org/eclipse/etrice/ui/common/dialogs/AbstractPropertyDialog.java
index 263a9b45a..0b25ec6ba 100644
--- a/plugins/org.eclipse.etrice.ui.common/src/org/eclipse/etrice/ui/common/dialogs/AbstractPropertyDialog.java
+++ b/plugins/org.eclipse.etrice.ui.common/src/org/eclipse/etrice/ui/common/dialogs/AbstractPropertyDialog.java
@@ -188,13 +188,12 @@ public abstract class AbstractPropertyDialog extends FormDialog {
boolean visible = !((IStatus) value).isOK();
validationLabel.setVisible(visible);
validationText.setVisible(visible);
+
+ Button okButton = getButton(IDialogConstants.OK_ID);
+ if (okButton!=null)
+ okButton.setEnabled(((IStatus) value).isOK());
}
- // initially disable ok button, validation is running after each change
- Button okButton = getButton(IDialogConstants.OK_ID);
- if (okButton!=null)
- okButton.setEnabled(false);
-
return bar;
}

Back to the top