ftpframe.java~3~
上传用户:lybcsm
上传日期:2007-04-26
资源大小:26k
文件大小:2k
- package ftpserver;
- import java.awt.*;
- import javax.swing.*;
- public class ftpframe extends JFrame{
- JPanel contentPane;
- Label labelframe=new Label();
- JTextArea textMessage = new JTextArea();
- JButton buttonclear = new JButton();
- JButton buttonstart = new JButton();
- JButton buttonstop = new JButton();
- public ftpframe() {
- try{
- jbInit();
- }
- catch(Exception e){
- e.printStackTrace();
- }
- }
- private void jbInit() throws Exception{//初始化界面并显示
- contentPane=(JPanel) this.getContentPane();
- contentPane.setLayout(null);
- labelframe.setFont(new java.awt.Font("Dialog", 0, 22));
- labelframe.setText("服务器处理日志信息:");
- labelframe.setBounds(new Rectangle(48, 98, 250, 22));
- contentPane.setPreferredSize(new Dimension(800, 600));
- textMessage.setText("");
- textMessage.setBounds(new Rectangle(52, 145, 393, 281));
- buttonclear.setBounds(new Rectangle(147, 449, 197, 47));
- buttonclear.setFont(new java.awt.Font("Dialog", 0, 22));
- buttonclear.setText("清 除 ");
- buttonstart.setBounds(new Rectangle(49, 40, 107, 38));
- buttonstart.setFont(new java.awt.Font("Dialog", 0, 16));
- buttonstart.setText("运行");
- buttonstop.setBounds(new Rectangle(188, 41, 119, 36));
- buttonstop.setFont(new java.awt.Font("Dialog", 0, 16));
- buttonstop.setText("停止");
- contentPane.add(labelframe, null);
- contentPane.add(textMessage, null);
- contentPane.add(buttonclear, null);
- contentPane.add(buttonstart, null);
- contentPane.add(buttonstop, null);
- enableEvents(AWTEvent.WINDOW_EVENT_MASK);
- this.setSize(new Dimension(578, 555));
- this.setResizable(false);
- this.setTitle("FTPServer");
- this.setVisible(true);
- }
- }