示例#1
0
        /// <summary>
        /// Define your own Main() in a partial class in ProgramLocal.cs
        /// </summary>
        /// <param name="args"></param>
        static void MainFallback(string[] args)
        {
            Log("Init.Main");

            Thread = new ReactivixThread(new ClientThread());

            Thread.Start((IReactivixThread context) => {
                Log("Init.Thread");
            });

            bool run = true;

            while (run)
            {
                Thread.Pipe();
                System.Threading.Thread.Sleep(10);
            }
        }
示例#2
0
        static void Main()
        {
            Thread = new ReactivixThread(new ClientThread());

            Thread.Start((IReactivixThread context) => {
                Log("Init.Thread");
            });

            /*
             * bool run = true;
             * while (run)
             * {
             *  Thread.Pipe();
             *  System.Threading.Thread.Sleep(10);
             * }
             */

            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            //ApplicationContext context = new ApplicationContext(new Form1());
            //context.
            //Application.Run();
            //Application.Idle += Application_Idle;

            //Application.Run(new Form1());
            Form1 main = new Form1();

            main.Show();

            var run = true;

            while (run)
            {
                Application.DoEvents();
                Thread.Pipe(main);
                System.Threading.Thread.Sleep(10);
            }

            //Application.RegisterMessageLoop()
        }