ボタンを押したらイベント
JButton btn = new JButton("event"); btn.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { //イベント内容 System.out.println("event"); } });
JButton btn = new JButton("event"); btn.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { //イベント内容 System.out.println("event"); } });