Run configaration's form refactored and some other forms too

This commit is contained in:
Evgeny Zakrevsky
2011-08-17 21:36:52 +04:00
parent 58ca60481d
commit 41c63cc31b
39 changed files with 483 additions and 430 deletions
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<form xmlns="http://www.intellij.com/uidesigner/form/" version="1" bind-to-class="com.intellij.execution.applet.AppletConfigurable">
<grid id="e5f4d" binding="myWholePanel" layout-manager="GridLayoutManager" row-count="7" column-count="1" same-size-horizontally="false" same-size-vertically="false" hgap="-1" vgap="-1">
<grid id="e5f4d" binding="myWholePanel" layout-manager="GridLayoutManager" row-count="8" column-count="1" same-size-horizontally="false" same-size-vertically="false" hgap="-1" vgap="-1">
<margin top="0" left="0" bottom="0" right="0"/>
<constraints>
<xy x="133" y="39" width="564" height="646"/>
<xy x="133" y="39" width="564" height="584"/>
</constraints>
<properties/>
<border type="none"/>
@@ -22,7 +22,7 @@
</constraints>
<properties>
<selected value="true"/>
<text resource-bundle="messages/ExecutionBundle" key="applet.configuration.applet.class.label"/>
<text resource-bundle="messages/ExecutionBundle" key="applet.configuration.applet.class.option"/>
</properties>
</component>
<component id="74d77" class="javax.swing.JRadioButton" binding="myURL">
@@ -37,33 +37,38 @@
</grid>
<component id="5dbf7" class="com.intellij.openapi.ui.LabeledComponent" binding="myPolicyFile">
<constraints>
<grid row="2" column="0" row-span="1" col-span="1" vsize-policy="0" hsize-policy="3" anchor="1" fill="1" indent="0" use-parent-layout="false"/>
<grid row="3" column="0" row-span="1" col-span="1" vsize-policy="0" hsize-policy="3" anchor="1" fill="1" indent="0" use-parent-layout="false"/>
</constraints>
<properties>
<componentClass value="com.intellij.openapi.ui.TextFieldWithBrowseButton"/>
<labelInsets top="0" left="0" bottom="5" right="0"/>
<labelInsets top="0" left="0" bottom="0" right="0"/>
<labelLocation value="West"/>
<labelPreferredSize width="212" height="16"/>
<text resource-bundle="messages/ExecutionBundle" key="applet.configuration.policy.file.label"/>
</properties>
</component>
<component id="67632" class="com.intellij.openapi.ui.LabeledComponent" binding="myVMParameters">
<constraints>
<grid row="3" column="0" row-span="1" col-span="1" vsize-policy="0" hsize-policy="3" anchor="1" fill="1" indent="0" use-parent-layout="false">
<grid row="4" column="0" row-span="1" col-span="1" vsize-policy="0" hsize-policy="3" anchor="1" fill="1" indent="0" use-parent-layout="false">
<preferred-size width="400" height="-1"/>
</grid>
</constraints>
<properties>
<componentClass value="com.intellij.ui.RawCommandLineEditor"/>
<labelInsets top="5" left="0" bottom="2" right="0"/>
<labelInsets top="0" left="0" bottom="0" right="0"/>
<labelLocation value="West"/>
<labelPreferredSize width="212" height="16"/>
<text resource-bundle="messages/ExecutionBundle" key="applet.configuration.vm.parameters.for.appletviewer.label"/>
</properties>
</component>
<component id="eac49" class="com.intellij.openapi.ui.LabeledComponent" binding="myModule">
<constraints>
<grid row="4" column="0" row-span="1" col-span="1" vsize-policy="0" hsize-policy="3" anchor="1" fill="1" indent="0" use-parent-layout="false"/>
<grid row="5" column="0" row-span="1" col-span="1" vsize-policy="0" hsize-policy="3" anchor="1" fill="1" indent="0" use-parent-layout="false"/>
</constraints>
<properties>
<componentClass value="javax.swing.JComboBox"/>
<labelInsets top="5" left="0" bottom="5" right="0"/>
<labelInsets top="0" left="0" bottom="0" right="0"/>
<labelLocation value="West"/>
<text resource-bundle="messages/ExecutionBundle" key="applet.configuration.use.classpath.and.jdk.of.module.label"/>
</properties>
</component>
@@ -75,16 +80,16 @@
<properties/>
<border type="none"/>
<children>
<grid id="dbe39" binding="myHTMLOptions" layout-manager="GridLayoutManager" row-count="1" column-count="2" same-size-horizontally="false" same-size-vertically="false" hgap="5" vgap="-1">
<margin top="5" left="5" bottom="5" right="5"/>
<grid id="dbe39" binding="myHTMLOptions" layout-manager="GridLayoutManager" row-count="1" column-count="2" same-size-horizontally="false" same-size-vertically="false" hgap="-1" vgap="-1">
<margin top="0" left="0" bottom="0" right="0"/>
<constraints>
<grid row="0" column="0" row-span="1" col-span="1" vsize-policy="7" hsize-policy="3" anchor="1" fill="1" indent="0" use-parent-layout="false"/>
</constraints>
<properties/>
<clientProperties>
<BorderFactoryClass class="java.lang.String" value="com.intellij.ui.IdeBorderFactory$SimpleWithIndent"/>
<BorderFactoryClass class="java.lang.String" value=""/>
</clientProperties>
<border type="etched" title-resource-bundle="messages/ExecutionBundle" title-key="applet.configuration.url.border"/>
<border type="none"/>
<children>
<component id="a2b70" class="javax.swing.JLabel" binding="myHtmlFileLabel">
<constraints>
@@ -104,8 +109,8 @@
</component>
</children>
</grid>
<grid id="71bb1" binding="myClassOptions" layout-manager="GridLayoutManager" row-count="3" column-count="1" same-size-horizontally="false" same-size-vertically="false" hgap="-1" vgap="7">
<margin top="5" left="5" bottom="5" right="5"/>
<grid id="71bb1" binding="myClassOptions" layout-manager="GridLayoutManager" row-count="3" column-count="1" same-size-horizontally="false" same-size-vertically="false" hgap="-1" vgap="-1">
<margin top="0" left="0" bottom="0" right="0"/>
<constraints>
<grid row="1" column="0" row-span="1" col-span="1" vsize-policy="0" hsize-policy="3" anchor="1" fill="1" indent="0" use-parent-layout="false"/>
</constraints>
@@ -113,9 +118,9 @@
<enabled value="true"/>
</properties>
<clientProperties>
<BorderFactoryClass class="java.lang.String" value="com.intellij.ui.IdeBorderFactory$SimpleWithIndent"/>
<BorderFactoryClass class="java.lang.String" value=""/>
</clientProperties>
<border type="etched" title-resource-bundle="messages/ExecutionBundle" title-key="applet.configuration.applet.class.border"/>
<border type="none"/>
<children>
<grid id="9c777" layout-manager="GridLayoutManager" row-count="1" column-count="4" same-size-horizontally="false" same-size-vertically="false" hgap="-1" vgap="-1">
<margin top="0" left="0" bottom="0" right="0"/>
@@ -252,12 +257,18 @@
</grid>
<vspacer id="8b063">
<constraints>
<grid row="6" column="0" row-span="1" col-span="1" vsize-policy="6" hsize-policy="1" anchor="0" fill="2" indent="0" use-parent-layout="false"/>
<grid row="7" column="0" row-span="1" col-span="1" vsize-policy="6" hsize-policy="1" anchor="0" fill="2" indent="0" use-parent-layout="false"/>
</constraints>
</vspacer>
<component id="b2d36" class="com.intellij.execution.ui.AlternativeJREPanel" binding="myAlternativeJREPanel">
<constraints>
<grid row="5" column="0" row-span="1" col-span="1" vsize-policy="3" hsize-policy="3" anchor="0" fill="1" indent="0" use-parent-layout="false"/>
<grid row="6" column="0" row-span="1" col-span="1" vsize-policy="3" hsize-policy="3" anchor="0" fill="1" indent="0" use-parent-layout="false"/>
</constraints>
<properties/>
</component>
<component id="9e31a" class="javax.swing.JSeparator">
<constraints>
<grid row="2" column="0" row-span="1" col-span="1" vsize-policy="7" hsize-policy="0" anchor="0" fill="1" indent="0" use-parent-layout="false"/>
</constraints>
<properties/>
</component>
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<form xmlns="http://www.intellij.com/uidesigner/form/" version="1" bind-to-class="com.intellij.execution.application.ApplicationConfigurable">
<grid id="93687" binding="myWholePanel" layout-manager="GridLayoutManager" row-count="6" column-count="1" same-size-horizontally="false" same-size-vertically="false" hgap="-1" vgap="10">
<grid id="93687" binding="myWholePanel" layout-manager="GridLayoutManager" row-count="6" column-count="1" same-size-horizontally="false" same-size-vertically="false" hgap="-1" vgap="-1">
<margin top="0" left="0" bottom="0" right="0"/>
<constraints>
<xy x="53" y="36" width="596" height="433"/>
@@ -21,9 +21,13 @@
</component>
<component id="50d08" class="com.intellij.openapi.ui.LabeledComponent" binding="myMainClass" custom-create="true">
<constraints>
<grid row="0" column="0" row-span="1" col-span="1" vsize-policy="0" hsize-policy="3" anchor="0" fill="1" indent="0" use-parent-layout="false"/>
<grid row="0" column="0" row-span="1" col-span="1" vsize-policy="0" hsize-policy="3" anchor="0" fill="1" indent="0" use-parent-layout="false">
<preferred-size width="154" height="25"/>
</grid>
</constraints>
<properties>
<labelLocation value="West"/>
<labelPreferredSize width="144" height="16"/>
<text resource-bundle="messages/ExecutionBundle" key="application.configuration.main.class.label"/>
</properties>
</component>
@@ -33,6 +37,7 @@
</constraints>
<properties>
<componentClass value="javax.swing.JComboBox"/>
<labelLocation value="West"/>
<text resource-bundle="messages/ExecutionBundle" key="application.configuration.use.classpath.and.jdk.of.module.label"/>
</properties>
</component>
@@ -45,8 +45,9 @@ public class AlternativeJREPanel extends JPanel {
super(new GridBagLayout());
myCbEnabled = new JCheckBox(ExecutionBundle.message("run.configuration.use.alternate.jre.checkbox"));
final GridBagConstraints gc = new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 1.0, 0, GridBagConstraints.NORTHWEST,
GridBagConstraints.HORIZONTAL, new Insets(2, -2, 2, 2), 0, 0);
myCbEnabled.setPreferredSize(new Dimension(154, 16));
final GridBagConstraints gc = new GridBagConstraints(0, 0, 1, 1, 0, 0, GridBagConstraints.WEST,
GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0);
add(myCbEnabled, gc);
myFieldWithHistory = new TextFieldWithHistory();
@@ -61,7 +62,8 @@ public class AlternativeJREPanel extends JPanel {
ExecutionBundle.message("run.configuration.select.jre.dir.label"),
null, BrowseFilesListener.SINGLE_DIRECTORY_DESCRIPTOR,
TextComponentAccessor.TEXT_FIELD_WITH_HISTORY_WHOLE_TEXT);
gc.insets.left = 20;
gc.gridx = 1;
gc.weightx = 1;
add(myPathField, gc);
InsertPathAction.addTo(myFieldWithHistory.getTextEditor());
@@ -20,6 +20,8 @@ import com.intellij.execution.ExecutionBundle;
import com.intellij.openapi.ui.LabeledComponent;
import com.intellij.ui.RawCommandLineEditor;
import java.awt.*;
public class CommonJavaParametersPanel extends CommonProgramParametersPanel {
private LabeledComponent<RawCommandLineEditor> myVMParameters;
@@ -33,6 +35,9 @@ public class CommonJavaParametersPanel extends CommonProgramParametersPanel {
ExecutionBundle.message("run.configuration.java.vm.parameters.label"));
copyDialogCaption(myVMParameters);
myVMParameters.setLabelLocation(BorderLayout.WEST);
myVMParameters.setLabelPreferredSize(super.getProgramParametersComponent().getLabelPreferredSize());
add(myVMParameters);
super.addComponents();
}