Skip to content

Commit

Permalink
Added some debug code for keypresses.
Browse files Browse the repository at this point in the history
  • Loading branch information
icculus committed Mar 23, 2016
1 parent f37c696 commit 6f9542e
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion keyhook.c
Expand Up @@ -21,9 +21,12 @@ static void keyhookCallback(XPointer priv, XRecordInterceptData *data)
const xEvent *xev = (const xEvent *) data->data;
if (data->category == XRecordFromServer)
{
const BYTE keycode = xev->u.u.detail;
if (xev->u.u.type == KeyPress)
{
const BYTE keycode = xev->u.u.detail;

//printf("Pressed X11 keycode %u\n", (unsigned int) keycode);

// !!! FIXME: don't hardcode these keycodes.
if ((keycode == 64) && (keyPressFlags == 0))
keyPressFlags++;
Expand Down

0 comments on commit 6f9542e

Please sign in to comment.