チェンジセット 719

差分発生行の前後
無視リスト:
コミット日時:
2008/06/28 09:54:14 (5 ヶ月前)
コミッタ:
yossy
ログメッセージ:

Thread: 既に開始されているスレッドは開始しないように (fixed #45)

ファイル:

凡例:

変更無し
追加
削除
更新
コピー
移動
  • as3/Thread/trunk/Thread.as3proj

    r653 r719  
    6969  <!-- Class files to compile (other referenced classes will automatically be included) --> 
    7070  <compileTargets> 
    71     <compile path="samples\urlloader\Sample.as" /> 
     71    <compile path="samples\hello\Sample.as" /> 
    7272  </compileTargets> 
    7373  <!-- Paths to exclude from the Project Explorer tree --> 
  • as3/Thread/trunk/src/org/libspark/thread/threads/progression/ThreadCommand.as

    r641 r719  
    147147import org.libspark.thread.Thread; 
    148148import flash.utils.setTimeout; 
     149import org.libspark.thread.ThreadState; 
    149150 
    150151class AdapterThread extends Thread 
     
    169170        { 
    170171                error(Object, errorHandler); 
    171                 thread.start(); 
     172                if (thread.state == ThreadState.NEW) { 
     173                        thread.start(); 
     174                } 
    172175                thread.join(); 
    173176        } 
  • as3/Thread/trunk/src/org/libspark/thread/utils/ParallelExecutor.as

    r653 r719  
    2929{ 
    3030        import org.libspark.thread.Thread; 
     31        import org.libspark.thread.ThreadState; 
    3132 
    3233        /** 
     
    5455                        // 全てのスレッドを開始 
    5556                        for each (var thread:Thread in _threads) { 
    56                                 thread.start(); 
     57                                if (thread.state == ThreadState.NEW) { 
     58                                        thread.start(); 
     59                                } 
    5760                        } 
    5861                         
  • as3/Thread/trunk/src/org/libspark/thread/utils/SerialExecutor.as

    r653 r719  
    2929{ 
    3030        import org.libspark.thread.Thread; 
     31        import org.libspark.thread.ThreadState; 
    3132 
    3233        /** 
     
    8990                         
    9091                        // スレッドを開始 
    91                         thread.start(); 
     92                        if (thread.state == ThreadState.NEW) { 
     93                                thread.start(); 
     94                        } 
    9295                        // 終了を待つ 
    9396                        thread.join();