public static Thread CreateThread(ThreadStart start) { var tsc = new ThreadStartContext(start); var t = new Thread(tsc.StartThread); tsc.Thread = t; return(t); }
public static Thread CreateThread(ParameterizedThreadStart start, int maxStackSize) { var tsc = new ThreadStartContext(start); var t = new Thread(tsc.StartThreadParameterized, maxStackSize); tsc.Thread = t; return(t); }