List of usage examples for javax.swing JApplet start
public void start()
From source file:Applet1c.java
public static void main(String[] args) { JApplet applet = new Applet1c(); JFrame frame = new JFrame("Applet1c"); // To close the application: frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); frame.getContentPane().add(applet);/* w ww. j a v a 2 s. c o m*/ frame.setSize(100, 50); applet.init(); applet.start(); frame.setVisible(true); }
From source file:WeatherWizard.java
public static void main(String[] args) { JFrame f = new JFrame("Weather Wizard"); f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); JApplet ap = new WeatherWizard(); ap.init();/* w w w.j a va2s.co m*/ ap.start(); f.add("Center", ap); f.pack(); f.setVisible(true); }
From source file:Box2.java
public static void run(JApplet applet, int width, int height) { JFrame frame = new JFrame(); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); frame.getContentPane().add(applet);//from w w w. ja v a2s .c o m frame.setSize(width, height); applet.init(); applet.start(); frame.setVisible(true); }