一个关于线程的题目在窗口里面启动线程

定义两个线程,线程1和线程2;建立一个窗口,在文本行中写入一个正整数,点击开始按钮,生成线程1,并使线程1睡眠正整数秒,开始按钮变为不可用,当睡眠结束,开始按钮变为可用。在此期间线程2不断计时,在一个标签中显示计时的数字。
下面就是我的代码:
import java.awt.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import javax.swing.*;
import javax.swing.event.ListDataListener;

public class Qimzn {
public static void main(String args[])
{
new ChuangKou("睡眠计时");
}

}
class ChuangKou extends JFrame
{
public ChuangKou(String name)
{
JFrame jf=new JFrame(name);
Container container=jf.getContentPane();
jf.setSize(600,600);
container.setBackground(Color.ORANGE);
jf.setVisible(true);//
jf.setLayout(new FlowLayout(1,10,10));//
jf.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);

                  JTextField d=new JTextField("提示信息",25);
                  container.add(d);
                  JLabel c=new JLabel("睡眠时间");
                container.add(c);
                  JTextField a=new JTextField("       ",7);
                 container.add(a);
                 JButton b=new JButton("开始");
                 container.add(b);
              class bAction implements ActionListener
                        public void actionPerformed(ActionEvent e)
                     {
                         class T1 extends Thread
                             {

                                        int i;
                                       public T1(int n)
                                      {
                                                i=n;
                                        }
                                         public void run()
                                          {
                                           System.out.println("线程1开始睡眠"+i+"秒!");
                                               try
                                             {
                                                          sleep(1000*i);
                                             }
                                                catch(Exception e)
                                             {}
                                            System.out.println("线程1醒来!");
                                    }
                         }
                      class T2 extends Thread
                        {
                                    public volatile boolean stop =false;
                               int i=0;

                                public void run()
                                 {
                                            while(!stop)
                                 {
                                    try
                                        {
                                                    sleep(1000);
                                    }
                                    catch(Exception e)
                                     {}
                                       i++;
                                     c.setText("睡眠时间为"+i);
                                  }
                          }

          }
          String str=a.getText();
          int n=Integer.parseInt(str);
          T1 thread01=new T1(n);
          T2 thread02=new T2();
          d.setText("线程1开始睡眠"+n+"秒"+"线程2开始计时!");
          thread01.start();
          thread02.start();
          try
          {
              Thread.sleep(1000*n);
          }
          catch(Exception e1)
          {}
          thread02.stop=true;

        }     
    }
    b.addActionListener(new bAction());




}

}

所以你的问题是啥呢?
实现上有错误?