/* * ButtonApplet.java * * Created on September 8, 2004, 1:43 PM */ /** * * @author wu_staff */ public class ButtonApplet extends java.applet.Applet { /** Initializes the applet ButtonApplet */ public void init() { initComponents(); } /** This method is called from within the init() method to * initialize the form. * WARNING: Do NOT modify this code. The content of this method is * always regenerated by the Form Editor. */ private void initComponents() {//GEN-BEGIN:initComponents textArea1 = new java.awt.TextArea(); button2 = new java.awt.Button(); checkbox1 = new java.awt.Checkbox(); textArea2 = new java.awt.TextArea(); button2.setLabel("button2"); button2.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { button2ActionPerformed(evt); } }); checkbox1.setLabel("checkbox1"); setLayout(new java.awt.BorderLayout()); add(textArea2, java.awt.BorderLayout.CENTER); }//GEN-END:initComponents private void button2ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_button2ActionPerformed textArea1.setText("hello Mom!"); }//GEN-LAST:event_button2ActionPerformed // Variables declaration - do not modify//GEN-BEGIN:variables private java.awt.Button button2; private java.awt.Checkbox checkbox1; private java.awt.TextArea textArea1; private java.awt.TextArea textArea2; // End of variables declaration//GEN-END:variables }