diff dwtx/dwtxhelper/Timer.d @ 167:862b05e0334a

Add a wrapper for Thread
author Frank Benoit <benoit@tionex.de>
date Tue, 09 Sep 2008 15:59:16 +0200
parents 86617aa6b5dd
children 1470d66733fa
line wrap: on
line diff
--- a/dwtx/dwtxhelper/Timer.d	Mon Sep 08 01:01:30 2008 +0200
+++ b/dwtx/dwtxhelper/Timer.d	Tue Sep 09 15:59:16 2008 +0200
@@ -2,7 +2,7 @@
 
 import dwtx.dwtxhelper.TimerTask;
 import tango.util.container.CircularList;
-import tango.core.Thread;
+import dwtx.dwtxhelper.JThread;
 import tango.core.sync.Mutex;
 import tango.core.sync.Condition;
 import tango.time.Time;
@@ -12,7 +12,7 @@
 
     alias CircularList!( TimerTask ) ListType;
 
-    private Thread thread;
+    private JThread thread;
     private ListType schedules;
     private Mutex mutex;
     private Condition cond;
@@ -26,8 +26,8 @@
         cond = new Condition( mutex );
 
         schedules = new ListType();
-        thread = new Thread( &run );
-        thread.isDaemon = isDaemon;
+        thread = new JThread( &run );
+        thread.setDaemon( isDaemon );
         thread.start();
     }
     private void run(){