private void StateChange(object sender, EqiupmentStateChangeEventArgs e)
 {
     if (OnStateChange != null)
     {
         OnStateChange(sender, e);
     }
 }
 private void ServerModule_OnStateChange(object sender, EqiupmentStateChangeEventArgs e)
 {
     StateChange(sender, e);
 }
Пример #3
0
 private void _monitor_OnStateChange(object sender, EqiupmentStateChangeEventArgs e)
 {
     try
     {
         // проверка на число подключенных активных дисплеев
         DisplayType displayType = e.EquipmentType as DisplayType;
         if (displayType != null && !displayType.IsHardware && e.IsOnLine)
         {
             WatchDog.WatchDogAction(_config.EventLog.WriteError, CheckLicense, _monitor.GetActiveDisplayNumber());
         }
         _globalNotifier.Notify(null, this, "EquipmentStateChange", e.EquipmentType, e.IsOnLine);
         //if (_callback != null) _callback.EquipmentStateChange(e.EquipmentType, e.IsOnLine);
     }
     catch (Exception ex)
     {
         _config.EventLog.WriteError(string.Format("ShowService._monitor_OnStateChange \n {0}", ex));
     }
 }
 void _monitor_OnStateChange(object sender, EqiupmentStateChangeEventArgs e)
 {
     if (_isWorked == 0 || _isPaused == 1 || _isInit == 1) return;
     if (e.IsOnLine)
         new Action<EquipmentType>(SendCommandToEquipment).BeginInvoke(
             e.EquipmentType, null, null);
 }
Пример #5
0
 protected void StateChange(object sender, EqiupmentStateChangeEventArgs args)
 {
     if (OnStateChange != null)
     {
         OnStateChange(sender, args);
     }
 }