Пример #1
0
        private void TelnetWindowInputSignalHandler(ThreadMessageBase message)
        {
            if (message is MatchScreenDefnMessage)
            {
                var defnMessage = message as MatchScreenDefnMessage;
                this.Model.MatchScreenDefn = defnMessage.ScreenDefn;

                if (this.Dispatcher.CheckAccess() == false)
                {
                    this.Dispatcher.BeginInvoke(
                        DispatcherPriority.Input, new ThreadStart(
                            () =>
                    {
                        if (defnMessage.ScreenDefn != null)
                        {
                            tbStatusBarMessage.Text = defnMessage.ScreenDefn.ScreenName;

                            // auto capture of content of every screen with a matching
                            // screen defn. Signal the capture thread to perform the capture.
                            if (this.Model.CaptureAuto == true)
                            {
                                var captureMessage = new CaptureContentMessage(
                                    this.Model.CaptureFolderPath, this.Model.CaptureAuto,
                                    defnMessage.ScreenDefn, defnMessage.ScreenContent);
                                this.CaptureThread.PostInputMessage(captureMessage);
                            }
                        }
                    }));
                }
            }
        }
Пример #2
0
 private void PostToProcessQueue(ThreadMessageBase Message)
 {
     if ((this.TypeDevice != null) &&
         (this.TypeDevice.Value == TypeTelnetDevice.Printer))
     {
         this.PrinterThread.PostInputMessage(Message);
     }
     else
     {
         this.MasterThread.PostInputMessage(Message);
     }
 }
Пример #3
0
 public static void PostInputMessage(
     this IThreadBase ThreadBase, ThreadMessageBase Message)
 {
     ThreadBase.InputQueue.Enqueue(Message);
 }
Пример #4
0
 private void MainWindow_InputSignalHandler(ThreadMessageBase Message)
 {
 }