Beispiel #1
0
 private void ThreadExecute(string path)
 {
     //������һ���߳�//
     Terminate(true);
     //��ʼ�µ��߳�//
     this.thread = new BackgroudFindFile(this, path, this.milliSeconds);
     this.thread.Resume();
 }
Beispiel #2
0
 public void WaitForComplete()
 {
     if (this.thread != null)
     {
         /*����ȴ������߳���ɲ����ͷ��̶߳��󣬷��򽫵��̶߳����Ѿ��ͷţ�
         �������߳���Ȼ���е������ͬʱ���ܹ���ֻ֤��һ����ͼ�߳���ִ�С�*/
         this.thread.WaitFor();
         //�ͷ��̶߳���//
         this.thread = null;
     }
 }