Example #1
0
        protected virtual void RaisePowerEvent(PowerEventArgs e)
        {
            EventHandler <PowerEventArgs> handler = OnPowerEvent;

            if (handler != null)
            {
                IsGo = false;
                handler(this, e);
                IsGo = true;
            }
        }
Example #2
0
 private void HandlePowerEvent(object sender, Bacodelib.PowerEventArgs e)
 {
     Invoke(new LowBattery(OnLowBattery), new Object[] { e.Message });
 }