mirror of
https://github.com/correl/mage.git
synced 2024-12-25 11:11:16 +00:00
Increased window size of pick choice dialog.
This commit is contained in:
parent
ed11d8e5ed
commit
da0100d3fd
3 changed files with 10 additions and 6 deletions
|
@ -22,13 +22,13 @@
|
|||
<Group type="102" alignment="1" attributes="0">
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="1" attributes="0">
|
||||
<Component id="jScrollPane1" alignment="0" pref="256" max="32767" attributes="0"/>
|
||||
<Component id="jScrollPane1" alignment="0" pref="335" max="32767" attributes="0"/>
|
||||
<Group type="102" alignment="1" attributes="0">
|
||||
<Component id="btnOk" min="-2" max="-2" attributes="0"/>
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Component id="btnCancel" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<Component id="lblMessage" alignment="0" pref="256" max="32767" attributes="0"/>
|
||||
<Component id="lblMessage" alignment="0" pref="335" max="32767" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
</Group>
|
||||
|
@ -40,7 +40,7 @@
|
|||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Component id="lblMessage" min="-2" max="-2" attributes="0"/>
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Component id="jScrollPane1" pref="119" max="32767" attributes="0"/>
|
||||
<Component id="jScrollPane1" pref="165" max="32767" attributes="0"/>
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="3" attributes="0">
|
||||
<Component id="btnCancel" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
|
|
|
@ -115,12 +115,12 @@ public class PickChoiceDialog extends MageDialog {
|
|||
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
|
||||
.addContainerGap()
|
||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
|
||||
.addComponent(jScrollPane1, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 256, Short.MAX_VALUE)
|
||||
.addComponent(jScrollPane1, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 335, Short.MAX_VALUE)
|
||||
.addGroup(layout.createSequentialGroup()
|
||||
.addComponent(btnOk)
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||
.addComponent(btnCancel))
|
||||
.addComponent(lblMessage, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 256, Short.MAX_VALUE))
|
||||
.addComponent(lblMessage, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 335, Short.MAX_VALUE))
|
||||
.addContainerGap())
|
||||
);
|
||||
layout.setVerticalGroup(
|
||||
|
@ -129,7 +129,7 @@ public class PickChoiceDialog extends MageDialog {
|
|||
.addContainerGap()
|
||||
.addComponent(lblMessage)
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||
.addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 115, Short.MAX_VALUE)
|
||||
.addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 165, Short.MAX_VALUE)
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||
.addComponent(btnCancel)
|
||||
|
@ -145,6 +145,7 @@ public class PickChoiceDialog extends MageDialog {
|
|||
}//GEN-LAST:event_btnOkActionPerformed
|
||||
|
||||
private void btnCancelActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnCancelActionPerformed
|
||||
this.lstChoices.clearSelection();
|
||||
this.hideDialog();
|
||||
}//GEN-LAST:event_btnCancelActionPerformed
|
||||
|
||||
|
|
|
@ -75,12 +75,15 @@ public class NameACardEffect extends OneShotEffect {
|
|||
switch(typeOfName) {
|
||||
case ALL:
|
||||
cardChoice.setChoices(CardRepository.instance.getNames());
|
||||
cardChoice.setMessage("Name a card");
|
||||
break;
|
||||
case NON_LAND_AND_NON_CREATURE_NAME:
|
||||
cardChoice.setChoices(CardRepository.instance.getNonLandAndNonCreatureNames());
|
||||
cardChoice.setMessage("Name a non land and non creature card");
|
||||
break;
|
||||
case NON_LAND_NAME:
|
||||
cardChoice.setChoices(CardRepository.instance.getNonLandNames());
|
||||
cardChoice.setMessage("Name a non land card");
|
||||
break;
|
||||
}
|
||||
cardChoice.clearChoice();
|
||||
|
|
Loading…
Reference in a new issue