mirror of
https://github.com/correl/mage.git
synced 2024-12-25 03:00:15 +00:00
* Password join value is now distinct from password you set of for a new table.
This commit is contained in:
parent
f7bce827fe
commit
4f6d3f3a1a
2 changed files with 3 additions and 2 deletions
|
@ -51,7 +51,7 @@ public class JoinTableDialog extends MageDialog {
|
||||||
public JoinTableDialog() {
|
public JoinTableDialog() {
|
||||||
initComponents();
|
initComponents();
|
||||||
newPlayerPanel.showLevel(false);
|
newPlayerPanel.showLevel(false);
|
||||||
txtPassword.setText(PreferencesDialog.getCachedValue(PreferencesDialog.KEY_NEW_TABLE_PASSWORD, ""));
|
txtPassword.setText(PreferencesDialog.getCachedValue(PreferencesDialog.KEY_NEW_TABLE_PASSWORD_JOIN, ""));
|
||||||
}
|
}
|
||||||
|
|
||||||
public void showDialog(UUID roomId, UUID tableId, boolean isTournament, boolean isLimited) {
|
public void showDialog(UUID roomId, UUID tableId, boolean isTournament, boolean isLimited) {
|
||||||
|
@ -148,7 +148,7 @@ public class JoinTableDialog extends MageDialog {
|
||||||
private void btnOKActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnOKActionPerformed
|
private void btnOKActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnOKActionPerformed
|
||||||
Session session = MageFrame.getSession();
|
Session session = MageFrame.getSession();
|
||||||
try {
|
try {
|
||||||
PreferencesDialog.saveValue(PreferencesDialog.KEY_NEW_TABLE_PASSWORD, txtPassword.getText());
|
PreferencesDialog.saveValue(PreferencesDialog.KEY_NEW_TABLE_PASSWORD_JOIN, txtPassword.getText());
|
||||||
if (isTournament) {
|
if (isTournament) {
|
||||||
joined = session.joinTournamentTable(roomId, tableId, this.newPlayerPanel.getPlayerName(), "Human", 1, DeckImporterUtil.importDeck(this.newPlayerPanel.getDeckFile()), this.txtPassword.getText());
|
joined = session.joinTournamentTable(roomId, tableId, this.newPlayerPanel.getPlayerName(), "Human", 1, DeckImporterUtil.importDeck(this.newPlayerPanel.getDeckFile()), this.txtPassword.getText());
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -164,6 +164,7 @@ public class PreferencesDialog extends javax.swing.JDialog {
|
||||||
// pref setting for new table dialog
|
// pref setting for new table dialog
|
||||||
public static final String KEY_NEW_TABLE_NAME = "newTableName";
|
public static final String KEY_NEW_TABLE_NAME = "newTableName";
|
||||||
public static final String KEY_NEW_TABLE_PASSWORD = "newTablePassword";
|
public static final String KEY_NEW_TABLE_PASSWORD = "newTablePassword";
|
||||||
|
public static final String KEY_NEW_TABLE_PASSWORD_JOIN = "newTablePasswordJoin";
|
||||||
public static final String KEY_NEW_TABLE_DECK_TYPE = "newTableDeckType";
|
public static final String KEY_NEW_TABLE_DECK_TYPE = "newTableDeckType";
|
||||||
public static final String KEY_NEW_TABLE_TIME_LIMIT = "newTableTimeLimit";
|
public static final String KEY_NEW_TABLE_TIME_LIMIT = "newTableTimeLimit";
|
||||||
public static final String KEY_NEW_TABLE_GAME_TYPE = "newTableGameType";
|
public static final String KEY_NEW_TABLE_GAME_TYPE = "newTableGameType";
|
||||||
|
|
Loading…
Reference in a new issue