Наследование: System.EventArgs
Пример #1
0
        public void OnControl(object s, CharacterEventArgs args)
        {
            switch (args.Character)
            {
            case ControlCharacters.CtrlV:
                string c = KeyboardEventDispatcher.GetNewClipboard();
                Insert(c);
                return;

            case ControlCharacters.CtrlC:
                if (text.Length > 0)
                {
                    KeyboardEventDispatcher.SetToClipboard(Text);
                }
                return;
            }
        }
Пример #2
0
        public static void EventInput_CharEntered(object sender, char c, int lParam)
        {
            CharacterEventArgs e = new CharacterEventArgs(c, lParam);

            if (char.IsControl(e.Character))
            {
                if (ReceiveCommand != null)
                {
                    ReceiveCommand(sender, e);
                }
            }
            else
            {
                if (ReceiveChar != null)
                {
                    ReceiveChar(sender, e);
                }
            }
        }
Пример #3
0
 public void OnChar(object s, CharacterEventArgs args)
 {
     Insert(args.Character);
 }