コード例 #1
0
 private Frm_MonitorDisplayMain()
 {
     InitializeComponent();
     MonitorAllConfig.Instance().MonitorDataChangedEvent += Frm_MonitorDisplayMain_MonitorDataChangedEvent;
     MonitorAllConfig.Instance().MonitorUIStatusChangedEvent += Frm_MonitorDisplayMain_MonitorUIStatusChangedEvent;
     MonitorAllConfig.Instance().LedScreenChangedEvent += Frm_MonitorDisplayMain_LedScreenChangedEvent;
     MonitorAllConfig.Instance().LedRegistationInfoEvent += Frm_MonitorDisplayMain_LedRegistationInfoEvent;
     MonitorAllConfig.Instance().CareServiceConnectionStatusChangedEvent += Frm_MonitorDisplayMain_CareServiceConnectionStatusChangedEvent;
     MonitorAllConfig.Instance().LedMonitoringConfigChangedEvent += Frm_MonitorDisplayMain_LedMonitoringConfigChangedEvent;
     _vm = new Frm_MonitorDisplayMain_VM();
     uC_MonitorDataListDW.DataGridClickEvent += uC_MonitorDataListDW_DataGridClickEvent;
     _topmostTimer = new System.Threading.Timer(ThreadSetTopMostCallback);
 }
コード例 #2
0
 private void SetMonitorData(string strData)
 {
     lock (_lockMonitordata)
     {
         _stopwatch.Stop();
         _fLogService.Debug("Monitor ReceiveData Timer:" + _stopwatch.ElapsedMilliseconds);
         ScreenMonitorData = CommandTextParser.GetDeJsonSerialization<AllMonitorData>(strData);
         if (MonitorDataChangedEvent != null)
         {
             MonitorDataChangedEvent(null, null);
         }
         else
         {
             Frm_MonitorDisplayMain_VM main_vm = new Frm_MonitorDisplayMain_VM();
             main_vm.OnCmdInitialize();
         }
         if (_sendMonitorErrMsg != null && ScreenMonitorData != null)
         {
             GetAllFaultAndAlarmInfo();
         }
     }
 }