Example #1
0
 private void KeyboardHookOnKeyDownCallback(KeyEventArgs e)
 {
     try
     {
         var keyMatch = LuaManager.KeyboardProvider.GetKeyPosition(e.KeyCode) ?? new KeyMatch(e.KeyCode, 0, 0);
         var args     = new LuaKeyPressEventArgs(e.KeyCode, keyMatch.X, keyMatch.Y);
         LuaInvoke(_profileModel, () => OnKeyboardKeyPressed(LuaManager.ProfileModule, args));
     }
     catch (Exception)
     {
         // ignored
     }
 }
Example #2
0
 protected virtual void OnKeyboardKeyPressed(LuaProfileModule profileModel, LuaKeyPressEventArgs e)
 {
     KeyboardKeyPressed?.Invoke(profileModel, e);
 }