private void Update(object sender, HardwareEventArgs args) { if (this.Enabled) { this.ChangeHardwareStatus((Hardware)Enum.Parse(typeof(Hardware), args.hardware.Name), args.hardware.GetStatus()); } }
protected virtual void OnStatusChanged(HardwareEventArgs e) { var handler = StatusChanged; if (handler != null) { handler(this, e); } }