forked from External/mage
Added possibility to show tournament panel and watch tournament games (if allowed at tournament start) for spectators .
This commit is contained in:
parent
001f8ec1e6
commit
9838dea551
24 changed files with 520 additions and 311 deletions
|
|
@ -594,6 +594,13 @@ public class MageFrame extends javax.swing.JFrame implements MageClient {
|
|||
|
||||
public void showTournament(UUID tournamentId) {
|
||||
try {
|
||||
for(Component component :desktopPane.getComponents()) {
|
||||
if (component instanceof TournamentPane &&
|
||||
((TournamentPane) component).getTournamentId().equals(tournamentId)) {
|
||||
setActive((TournamentPane) component);
|
||||
return;
|
||||
}
|
||||
}
|
||||
TournamentPane tournamentPane = new TournamentPane();
|
||||
desktopPane.add(tournamentPane, JLayeredPane.DEFAULT_LAYER);
|
||||
tournamentPane.setMaximum(true);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue