Class Tracksail.CreateGameActionListener

java.lang.Object
  extended byTracksail.CreateGameActionListener
All Implemented Interfaces:
java.awt.event.ActionListener, java.util.EventListener
Enclosing class:
Tracksail

class Tracksail.CreateGameActionListener
extends java.lang.Object
implements java.awt.event.ActionListener

Handles clicking the 'create game' button.


Constructor Summary
(package private) Tracksail.CreateGameActionListener()
           
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent e)
          Attempt to create a race in the server for this player.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Tracksail.CreateGameActionListener

Tracksail.CreateGameActionListener()
Method Detail

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent e)
Attempt to create a race in the server for this player.

We read from the text field the requested name for the race and create a race with that name to the server. If the server returns ok, we move to the racing state and the player is set as the master player for the created race.

Specified by:
actionPerformed in interface java.awt.event.ActionListener
Parameters:
e - ActionEvent event