testmybutton.java

来自「这是一个java工程」· Java 代码 · 共 32 行

JAVA
32
字号
/**
 * @(#)TestMyButton.java
 *
 * TestMyButton application
 *
 * @author 
 * @version 1.00 2009/2/15
 */
 import java.awt.*;
 import java.awt.event.*;
public class TestMyButton extends Frame {
	public TestMyButton (){
		addWindowListener(new WindowAdapter(){
			public void windowClosing(WindowEvent e){
				dispose();
				System.exit();
			}
		});
	}
    
    public static void main(String[] args) {
    	System.out.println("Staring TestMyButton...");
    	TestMyButton mainFrame = new TestMyButton();
    	mainFrame.setSize(400,400);
    	mainFrame.setTitle("TestMyButton");
    	mainFrame.setVisible(true);
    	
    	// TODO, add your application code
    	//System.out.println("Hello World!");
    }
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?