示例#1
0
        public override bool Equals(object obj)
        {
            TerminalKeyEventArgs k = obj as TerminalKeyEventArgs;

            if (k == null)
            {
                return(false);
            }

            if (this.KeyCode == Keys.None)
            {
                return(this.KeyCode == k.KeyCode && this.Modifier == k.Modifier);
            }
            else
            {
                return(this.KeyChar == k.KeyChar);
            }
        }
示例#2
0
 /// <summary>
 /// Call this function to send a non-printable key, such as arrow keys,
 /// function keys, etc. This should not be used to send printable keys,
 /// except when the intent is to substitute it for a different key.
 /// </summary>
 /// <param name="KeyCode"></param>
 public virtual void SendKey(TerminalKeyEventArgs terminalKey)
 {
     //System.Diagnostics.Debug.WriteLine("Keypress: " + KeyCode.ToString());
     SendChar(terminalKey.KeyChar);
 }