import javax.microedition.midlet.*; import javax.microedition.lcdui.*; public class Main extends MIDlet implements Runnable { public Display display; private Thread mainThread; private Menu menu; public Main(){ display=Display.getDisplay(this); mainThread=new Thread(this); menu=new Menu(); } public void startApp() { mainThread.start(); destroyApp(true); } public void pauseApp() {} public void destroyApp(boolean unconditional) { notifyDestroyed(); } public void run() { display.setCurrent(menu); mainThread.sleep(2000); } }