[jbosstools-commits] JBoss Tools SVN: r6941 - trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/wizards/appregister.
jbosstools-commits at lists.jboss.org
jbosstools-commits at lists.jboss.org
Fri Mar 14 14:15:18 EDT 2008
Author: scabanovich
Date: 2008-03-14 14:15:17 -0400 (Fri, 14 Mar 2008)
New Revision: 6941
Modified:
trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/wizards/appregister/AppRegisterComponent.java
Log:
JBIDE-1849
Modified: trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/wizards/appregister/AppRegisterComponent.java
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/wizards/appregister/AppRegisterComponent.java 2008-03-14 18:13:51 UTC (rev 6940)
+++ trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/wizards/appregister/AppRegisterComponent.java 2008-03-14 18:15:17 UTC (rev 6941)
@@ -29,6 +29,7 @@
import org.jboss.tools.common.model.ui.attribute.editor.ExtendedFieldEditor;
import org.jboss.tools.common.model.ui.attribute.editor.IMutableFieldEditor;
import org.jboss.tools.common.model.ui.attribute.editor.IPropertyEditor;
+import org.jboss.tools.common.model.ui.attribute.editor.MutableComboBoxFieldEditor;
import org.jboss.tools.common.model.ui.attribute.editor.MutableMultipleChoiceFieldEditor;
import org.eclipse.jface.window.Window;
@@ -338,6 +339,13 @@
Shell shell = (Shell)p.get("shell");
IServer server = newServer(shell);
if(server == null) return -1;
+
+ IModelPropertyEditorAdapter a = support.getPropertyEditorAdapterByName(ATTR_RUNTIME);
+ if(server.getRuntime() != null && !server.getRuntime().getName().equals(a.getValue())) {
+ MutableComboBoxFieldEditor ed1 = (MutableComboBoxFieldEditor)support.getFieldEditorByName(ATTR_RUNTIME);
+ ed1.setNewValue(server.getRuntime().getName());
+ }
+
p.setProperty("value", server.getName());
initTargetServerValue();
MutableMultipleChoiceFieldEditor ed = (MutableMultipleChoiceFieldEditor)support.getFieldEditorByName(ATTR_TARGET_SERVER);
More information about the jbosstools-commits
mailing list