Code Search for Developers
 
 
  

OpenGameAction.java from The Geronimo Project at Krugle


Show OpenGameAction.java syntax highlighted

package geronimo.hoshigo.control.game;

import geronimo.hoshigo.model.game.Game;
import geronimo.hoshigo.view.IconRegistry;
import geronimo.hoshigo.view.IconRegistry.IconSize;

import org.eclipse.jface.action.Action;

/**
 * Action de fermeture d'une partie. On ne peut fermer qu'un match amical
 * @author Geronimo
 */
public class OpenGameAction extends Action
{
	private static OpenGameAction instance;
	
	/**
	 * Création de l'action. Privé car on n'autorise qu'une seule instance
	 * de la classe.
	 */
	private OpenGameAction()
	{
		super();
		this.setText("&Ouvrir une partie...@Ctrl+O");
		this.setImageDescriptor( IconRegistry.getDescriptor("open_game",IconSize.SMALL) );
		this.setEnabled(true);
	}
	

	public void setActiveGame(Game game)
	{
	}
	
	/**
	 * Accès à l'instance de la classe.
	 * @return Retourne l'instance
	 */
	public synchronized static OpenGameAction getInstance()
	{
		// Creation de l'instance au premier appel
		if(instance == null)
		{
			instance = new OpenGameAction();
		}
		return instance;
	}

	/**
	 * Lancement de l'action. Supprime la partie
	 */
	public void run()
	{
		// TODO implémenter
	}
}




See more files for this project here

The Geronimo Project

The Geronimo project concists of two software :\n- Geronimo Hoshigo : a playable graphical user interface to play Go\n- Geronimo Margo : a artificial intelligence program which plays Go

Project homepage: http://sourceforge.net/projects/geronimo
Programming language(s): Java,Pascal,Perl,PHP
License: gpl2

  CloseGameAction.java
  GameActionManager.java
  NewGameAction.java
  OpenGameAction.java
  SaveGameAction.java
  SaveGameAsAction.java