Esempio n. 1
0
        private void FlashcardTester_KeyDown(object sender, KeyEventArgs e)
        {
            switch (e.KeyCode)
            {
            case Keys.D:
                RightBtn.PerformClick();
                break;

            case Keys.A:
                LeftBtn.PerformClick();
                break;

            case Keys.F:
                FlashcardBtn.PerformClick();
                break;
            }
        }
        private void FlashcardsEditor_KeyPress(object sender, KeyPressEventArgs e)
        {
            if (DescTxt.Visible && DescTxt.Focused)
            {
                return;
            }

            switch (char.ToUpper(e.KeyChar))
            {
            case 'D':
                RightBtn.PerformClick();
                break;

            case 'A':
                LeftBtn.PerformClick();
                break;
            }
        }