Exemple #1
0
        private void FormAreaSelectionTest_KeyDown(object sender, KeyEventArgs e)
        {
            switch (e.KeyCode)
            {
            // press ESC to close the window
            case Keys.Escape:
                this.Close();
                break;

            // press number keys to set gaze display mode
            case Keys.D1:
                gazeDisplayMode = GazeDisplayMode.None;
                break;

            case Keys.D2:
                gazeDisplayMode = GazeDisplayMode.Individal;
                break;

            case Keys.D3:
                gazeDisplayMode = GazeDisplayMode.Average;
                break;

            // press key S to show settings dialog
            case Keys.S:
                FormSettings f = new FormSettings("Area Selection Settings", this.settings);
                f.ShowDialog(this);
                break;

            case Keys.V:
                timerVirtualGazeTimer.Enabled = !timerVirtualGazeTimer.Enabled;
                break;
            }
        }
        private void FormCalibration_KeyDown(object sender, KeyEventArgs e)
        {
            switch (e.KeyCode)
            {
            // press ESC to close the window
            case Keys.Escape:
                this.Close();
                break;

            // press key S to show settings dialog
            case Keys.S:
                FormSettings f = new FormSettings("Calibration Settings", this.settings);
                f.ShowDialog(this);
                break;
            }
        }