Beispiel #1
0
 protected override void OnAbort()
 {
     if (CurrentAsyncThread != null)
     {
         CurrentAsyncThread.Abort();                  // it is not beautiful but there is no other way to stop it.
     }
 }
Beispiel #2
0
 protected override void OnAbort()
 {
     if (CurrentAsyncThread != null)
     {
         CurrentAsyncThread.Abort();
     }
 }
 protected override void OnClose(TimeSpan timeout)
 {
     if (CurrentAsyncThread != null)
     {
         if (!CancelAsync(timeout))
         {
             CurrentAsyncThread.Abort();
         }
     }
 }
Beispiel #4
0
 protected override void OnClose(TimeSpan timeout)
 {
     if (CurrentAsyncThread != null)
     {
         if (!CancelAsync(timeout))
         {
             if (CurrentAsyncThread != null)                     // being careful
             {
                 CurrentAsyncThread.Abort();                     // it is not beautiful but there is no other way to stop it.
             }
         }
     }
 }