private void Vacuum_Click(object sender, RoutedEventArgs e) { mTrendModel.PlotType = TrendPlotType.Vacuum; TrendView.LoadView(); mController.ConvertTrendPageModel(); TrendView.UpdatePlot(); }
public void StartUpdatePlotServer() { Thread mUpdateUIRunThread = new Thread(() => { ProcessStatus status = ProcessStatus.UNKNOWN; while (mUpdatePlot) { if (mTrendModel.TubeIndex != 0) { if (!mHoldUpdatePlot) { this.Dispatcher.BeginInvoke(DispatcherPriority.Normal, (ThreadStart) delegate() { mController.ConvertTrendPageModel(); TrendView.UpdatePlot(); }); } } Thread.Sleep(1000); } }); mUpdatePlot = true; mUpdateUIRunThread.IsBackground = true; mUpdateUIRunThread.Start(); }
public void LoadPage(byte selectedTube) { log.Info("TubeTrendPage"); mTrendModel.TubeIndex = selectedTube; mTrendModel.PlotType = TrendPlotType.Temperature; Visibility = Visibility.Visible; TrendView.LoadView(); mController.ConvertTrendPageModel(); TrendView.UpdatePlot(); ContinueUpdatePlot(); }