예제 #1
0
 public void IncresedLiquidTemperature(Kettle k, WarningLED warning)
 {
     if (k.KettelOn)
     {
         Temperature += 10;
     }
     IncreasernTemperature += warning.RisingTemperature;
     IncreasernTemperature.Invoke(this);
     if (warning.GreenLED)
     {
         k.LED = Color.Green;
     }
 }
예제 #2
0
 public void PressedPowerButton(Kettle k, WarningLED warning)
 {
     KettlePowerOn += warning.TurnKettleOn;
     if (!k.KettelOn)
     {
         KettlePowerOn.Invoke(k);
     }
     else
     {
         k.KettelOn = false;
         k.LED      = Color.Off;
         Liquid     = null;
     }
 }
예제 #3
0
 public void TurnKettleOn(Kettle k)
 {
     k.KettelOn = true;
     k.LED      = Color.Red;
 }