Exemplo n.º 1
0
        private void toolMode_Click(object sender, EventArgs e)
        {
            if (m_currentMode == KeypadMode.KeyInput)
            {
                m_currentMode = KeypadMode.Mapping;
                this.tabControl1.SelectedTab = tpMapping;
            }
            else
            {
                m_currentMode = KeypadMode.KeyInput;
                this.tabControl1.SelectedTab = tpInput;
            }

            UpdateMode();
        }
Exemplo n.º 2
0
        public static KeypadForm GetKeypadForm(string text, KeypadMode Mode)
        {
            if (KeypadFormObject == null)
            {
                KeypadFormObject = new KeypadForm();
            }

            KeypadFormObject.ClientSize   = new System.Drawing.Size(209, 254);
            KeypadFormObject.isFirstenter = true;
            KeypadFormObject.KeyText      = text;
            KeypadFormObject.mode         = Mode;

            KeypadFormObject.Location = new Point((Screen.PrimaryScreen.WorkingArea.Width - KeypadFormObject.Width) / 2,
                                                  (Screen.PrimaryScreen.WorkingArea.Height - KeypadFormObject.Height) / 2
                                                  );

            return(KeypadFormObject);
        }