Пример #1
0
        private void tsmDelay_Click(object sender, EventArgs e)
        {
            KB9TextBox t   = GetFocusedTextBox();
            frmDelay   frm = new frmDelay();
            decimal    d   = frm.InputDelay();

            if (d <= 0)
            {
                return;
            }

            /*
             * d *= 10; //delay time is nx0.1 format, so need to x10 to make string
             * int n = (int)d;
             * string s = n.ToString();
             *
             * s = "Pause" + s;
             * */
            string s = frmDelay.makePauseString(d);

            t.AddKeyCode(s, true);
            //frm.ShowDialog();
        }
Пример #2
0
        private void tsbDelay_Click(object sender, EventArgs e)
        {
            frmOnScreenKbd.Instance().Hide();
            KB9TextBox t = GetFocusedTextBox();

            if (t == null)
            {
                return;
            }
            frmDelay frm = new frmDelay();
            decimal  d   = frm.InputDelay();

            if (d <= 0)
            {
                return;
            }
            //d *= 10; //delay time is nx0.1 format, so need to x10 to make string
            //int n = (int)d;
            //string s = n.ToString();
            //s = "Pause" + s;
            string s = frmDelay.makePauseString(d);

            t.AddKeyCode(s, true);
        }