public static Sharpen.Thread CurrentThread() { if (wrapperThread == null) { wrapperThread = new Sharpen.Thread (System.Threading.Thread.CurrentThread); } return wrapperThread; }
public void Run() { lock (this) { thread = Thread.CurrentThread(); } try { if (!canceled) { Action.Run(); } } finally { lock (this) { thread = null; doneEvent.Set(); completed = true; } } }