示例#1
0
 static void HostedMain()
 {
     //Initialize sync context
     SynchronizationContext.SetSynchronizationContext(new WindowsFormsSynchronizationContext());
     var comm = new CommChannel(Console.OpenStandardInput(), Console.OpenStandardOutput());
     Console.SetOut(new NullTextWriter());
     Console.SetError(new NullTextWriter());
     comm.Disposed += () => Process.GetCurrentProcess().Kill();
     comm.SendMessage(new StateMessage("Staying awhile and listening..."));
     var service = new PerspexAppHost(comm);
     service.Start();
     Application.Run();
 }
示例#2
0
 internal HostedAppModel(PerspexAppHost host)
 {
     _host = host;
     Background = Settings.Background;
 }
示例#3
0
 internal HostedAppModel(PerspexAppHost host)
 {
     _host      = host;
     Background = Settings.Background;
 }