import javax.microedition.lcdui.Display;
import javax.microedition.lcdui.Graphics;
import javax.microedition.lcdui.game.GameCanvas;
public class GameOver extends GameCanvas
{
private Graphics g;
public GameOver()
{
super(false);
g=getGraphics();
}
public void showGameOver()
{
Display.getDisplay(BallMidlet.instance).setCurrent(this);
g.drawString("GameOver!",100,150,20);
this.flushGraphics();
try{Thread.sleep(4000);}
catch(Exception e){}
BallMidlet.instance.quitApp();
}
}