Class RandomArmyDialog

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, RootPaneContainer, WindowConstants

public class RandomArmyDialog extends AbstractRandomArmyDialog
This is the random army dialog shown in MM's lobby and game (reinforcement), where the system was initially developed. This dialog is tied to the ClientGUI, Client and Game states.
See Also:
  • Constructor Details

    • RandomArmyDialog

      public RandomArmyDialog(JFrame parent, ClientGUI clientGui)
      Creates a random army dialog for the given parent frame and ClientGUI. This dialog is specialized towards use in MM's lobby and game.
      Parameters:
      parent - A parent frame for the dialog
      clientGui - The ClientGUI this dialog operates on
  • Method Details

    • createButtonsPanel

      protected JComponent createButtonsPanel()
      Description copied from class: AbstractRandomArmyDialog
      Override to add buttons or other components to the bottom of the dialog. The returned component is added when setVisible(true) is called for the first time; it is added as BorderLayout.SOUTH and is therefore stretched to the width of the dialog.
      Specified by:
      createButtonsPanel in class AbstractRandomArmyDialog
      Returns:
      A button panel for the dialog
    • setPlayerFromClient

      public void setPlayerFromClient(Client c)
    • setVisible

      public void setVisible(boolean show)
      Overrides:
      setVisible in class AbstractRandomArmyDialog
    • dispose

      public void dispose()
      Overrides:
      dispose in class Window