Skip to content

Commit

Permalink
UI: fixed conditional gradle version info label.
Browse files Browse the repository at this point in the history
apache#5274 overlooked an invisible label which is only visible if
an unsupported version is selected in the combo box. This
fixes the layout so that making the label visible does not disturb
other UI components.
  • Loading branch information
mbien committed Jan 22, 2023
1 parent ad297ed commit 3d4fb68
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 45 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -181,32 +181,14 @@
<Group type="102" attributes="0">
<EmptySpace max="-2" attributes="0"/>
<Group type="103" groupAlignment="0" attributes="0">
<Group type="102" alignment="0" attributes="0">
<Component id="lblGradleUserHome" min="-2" max="-2" attributes="0"/>
<EmptySpace min="-2" pref="9" max="-2" attributes="0"/>
<Group type="103" groupAlignment="0" attributes="0">
<Group type="102" attributes="0">
<EmptySpace min="-2" pref="231" max="-2" attributes="0"/>
<Component id="lbVersionInfo" pref="2" max="32767" attributes="0"/>
<EmptySpace min="-2" pref="78" max="-2" attributes="0"/>
</Group>
<Group type="102" alignment="1" attributes="0">
<Component id="tfGradleUserHome" max="32767" attributes="0"/>
<EmptySpace max="-2" attributes="0"/>
<Component id="btGradleUserHome" linkSize="3" min="-2" pref="105" max="-2" attributes="0"/>
</Group>
</Group>
<EmptySpace min="-2" max="-2" attributes="0"/>
<Component id="btDefaultHome" min="-2" pref="105" max="-2" attributes="0"/>
</Group>
<Group type="102" alignment="0" attributes="0">
<Component id="lblGradleDistribution" min="-2" max="-2" attributes="0"/>
<EmptySpace max="-2" attributes="0"/>
<Group type="103" groupAlignment="0" attributes="0">
<Group type="102" alignment="0" attributes="0">
<Component id="rbUseStandardGradle" min="-2" max="-2" attributes="0"/>
<EmptySpace max="-2" attributes="0"/>
<Component id="cbGradleVersion" max="32767" attributes="0"/>
<Component id="cbGradleVersion" pref="107" max="32767" attributes="0"/>
</Group>
<Group type="102" alignment="0" attributes="0">
<Component id="rbUseCustomGradle" min="-2" max="-2" attributes="0"/>
Expand All @@ -225,6 +207,23 @@
</Group>
<EmptySpace min="0" pref="0" max="32767" attributes="0"/>
</Group>
<Group type="102" alignment="0" attributes="0">
<Component id="lblGradleUserHome" min="-2" max="-2" attributes="0"/>
<EmptySpace min="-2" pref="9" max="-2" attributes="0"/>
<Group type="103" groupAlignment="0" attributes="0">
<Group type="102" attributes="0">
<EmptySpace min="6" pref="6" max="-2" attributes="0"/>
<Component id="lbVersionInfo" max="32767" attributes="0"/>
</Group>
<Group type="102" alignment="0" attributes="0">
<Component id="tfGradleUserHome" max="32767" attributes="0"/>
<EmptySpace max="-2" attributes="0"/>
<Component id="btGradleUserHome" linkSize="3" min="-2" pref="105" max="-2" attributes="0"/>
<EmptySpace min="-2" max="-2" attributes="0"/>
<Component id="btDefaultHome" min="-2" pref="105" max="-2" attributes="0"/>
</Group>
</Group>
</Group>
</Group>
<EmptySpace min="2" pref="2" max="-2" attributes="0"/>
</Group>
Expand All @@ -233,32 +232,32 @@
<DimensionLayout dim="1">
<Group type="103" groupAlignment="0" attributes="0">
<Group type="102" alignment="0" attributes="0">
<EmptySpace max="32767" attributes="0"/>
<EmptySpace min="-2" max="-2" attributes="0"/>
<Group type="103" groupAlignment="3" attributes="0">
<Component id="lblGradleUserHome" alignment="3" min="-2" max="-2" attributes="0"/>
<Component id="tfGradleUserHome" alignment="3" min="-2" max="-2" attributes="0"/>
<Component id="btGradleUserHome" alignment="3" min="-2" max="-2" attributes="0"/>
<Component id="btDefaultHome" alignment="3" min="-2" max="-2" attributes="0"/>
</Group>
<EmptySpace max="-2" attributes="0"/>
<Component id="lbVersionInfo" min="-2" max="-2" attributes="0"/>
<EmptySpace max="-2" attributes="0"/>
<EmptySpace min="-2" max="-2" attributes="0"/>
<Component id="lbVersionInfo" max="32767" attributes="0"/>
<EmptySpace min="-2" max="-2" attributes="0"/>
<Group type="103" groupAlignment="3" attributes="0">
<Component id="lblGradleDistribution" alignment="3" min="-2" max="-2" attributes="0"/>
<Component id="cbGradleVersion" alignment="3" min="-2" max="-2" attributes="0"/>
<Component id="rbUseStandardGradle" alignment="3" min="-2" max="-2" attributes="0"/>
</Group>
<EmptySpace max="-2" attributes="0"/>
<EmptySpace min="-2" max="-2" attributes="0"/>
<Group type="103" groupAlignment="3" attributes="0">
<Component id="rbUseCustomGradle" alignment="3" min="-2" max="-2" attributes="0"/>
<Component id="tfUseCustomGradle" alignment="3" min="-2" max="-2" attributes="0"/>
<Component id="btUseCustomGradle" alignment="3" min="-2" max="-2" attributes="0"/>
</Group>
<EmptySpace type="unrelated" max="-2" attributes="0"/>
<EmptySpace type="unrelated" min="-2" max="-2" attributes="0"/>
<Component id="cbPreferWrapper" min="-2" max="-2" attributes="0"/>
<EmptySpace max="-2" attributes="0"/>
<EmptySpace min="-2" max="-2" attributes="0"/>
<Component id="cbStartDaemonOnStart" min="-2" max="-2" attributes="0"/>
<EmptySpace max="-2" attributes="0"/>
<EmptySpace min="-2" max="-2" attributes="0"/>
<Component id="cbSilentInstall" min="-2" max="-2" attributes="0"/>
</Group>
</Group>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -265,28 +265,14 @@ public void actionPerformed(java.awt.event.ActionEvent evt) {
.addGroup(jPanel1Layout.createSequentialGroup()
.addContainerGap()
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(lblGradleUserHome)
.addGap(9, 9, 9)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addGap(231, 231, 231)
.addComponent(lbVersionInfo, javax.swing.GroupLayout.DEFAULT_SIZE, 2, Short.MAX_VALUE)
.addGap(78, 78, 78))
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()
.addComponent(tfGradleUserHome)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(btGradleUserHome, javax.swing.GroupLayout.PREFERRED_SIZE, 105, javax.swing.GroupLayout.PREFERRED_SIZE)))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(btDefaultHome, javax.swing.GroupLayout.PREFERRED_SIZE, 105, javax.swing.GroupLayout.PREFERRED_SIZE))
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(lblGradleDistribution)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(rbUseStandardGradle)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(cbGradleVersion, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
.addComponent(cbGradleVersion, 0, 107, Short.MAX_VALUE))
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(rbUseCustomGradle)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
Expand All @@ -298,7 +284,20 @@ public void actionPerformed(java.awt.event.ActionEvent evt) {
.addComponent(cbSilentInstall)
.addComponent(cbStartDaemonOnStart)
.addComponent(cbPreferWrapper))
.addGap(0, 0, Short.MAX_VALUE)))
.addGap(0, 0, Short.MAX_VALUE))
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(lblGradleUserHome)
.addGap(9, 9, 9)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addGap(6, 6, 6)
.addComponent(lbVersionInfo, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(tfGradleUserHome)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(btGradleUserHome, javax.swing.GroupLayout.PREFERRED_SIZE, 105, javax.swing.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(btDefaultHome, javax.swing.GroupLayout.PREFERRED_SIZE, 105, javax.swing.GroupLayout.PREFERRED_SIZE)))))
.addGap(2, 2, 2))
);

Expand All @@ -307,14 +306,14 @@ public void actionPerformed(java.awt.event.ActionEvent evt) {
jPanel1Layout.setVerticalGroup(
jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addContainerGap()
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(lblGradleUserHome)
.addComponent(tfGradleUserHome, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(btGradleUserHome)
.addComponent(btDefaultHome))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(lbVersionInfo)
.addComponent(lbVersionInfo, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(lblGradleDistribution)
Expand Down

0 comments on commit 3d4fb68

Please sign in to comment.