public override void RegionRedEnter(GazeControllerEventArgs e)
 {
     this.RegionEnter(e);
 }
 public override void RegionGreenLeave(GazeControllerEventArgs e)
 {
     this.RegionLeave(e);
 }
 public override void RegionRedActivate(GazeControllerEventArgs e)
 {
     this.RegionActivate(e);
 }
 private void RegionLeave(GazeControllerEventArgs e)
 {
     this.DisplayLine2 = "";
 }
 public override void RegionBlueActivate(GazeControllerEventArgs e)
 {
     this.NextState = EngineStates.Idle;
 }
 private void RegionRedLeave(object sender, GazeControllerEventArgs e)
 {
     this.states[this.currentState].RegionRedLeave(e);
 }
 private void RegionEnter(GazeControllerEventArgs e)
 {
     this.DisplayLine2 = string.Format("Region -> {0}", e.Region.Name);
 }
 private void RegionYellowLeave(object sender, GazeControllerEventArgs e)
 {
 }
 private void RegionGreenEnter(object sender, GazeControllerEventArgs e)
 {
     this.states[this.currentState].RegionGreenEnter(e);
 }
 public virtual void RegionGreenEnter(GazeControllerEventArgs e)
 {
 }
        private void RegionYellowActivate(object sender, GazeControllerEventArgs e)
        {
            //  Go in alarm state if not else return to idle state
            if (this.currentState != EngineStates.Alarm)
            {
                this.SwitchState(EngineStates.Alarm);

                foreach (var state in this.states)
                    state.Value.Reset();
            }
            else
            {
                this.SwitchState(EngineStates.Idle);
            }
        }
 public virtual void RegionGreenActivate(GazeControllerEventArgs e)
 {
 }
 public virtual void RegionDownLeave(GazeControllerEventArgs e)
 {
 }
 public virtual void RegionCenterActivate(GazeControllerEventArgs e)
 {
 }
 private static void RegionLeave(object sender, GazeControllerEventArgs e)
 {
     Console.WriteLine(" Gaze left the {0} region, time: {1} s", e.Region.Name, e.Region.TimeAccumulator.ToString());
 }
 private static void RegionActivate(object sender, GazeControllerEventArgs e)
 {
     Console.WriteLine(" Activation of the {0} region was tiggered, it took: {1} s", e.Region.Name, e.Region.TimeAccumulator.ToString());
 }