aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/programs/Xserver/xkb/xkbEvents.c
diff options
context:
space:
mode:
authorMike Gabriel <mike.gabriel@das-netzwerkteam.de>2019-06-22 11:32:42 +0200
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2019-06-22 11:32:42 +0200
commitabf3741362f4c200945db6403fcd54df6754d4af (patch)
treeea7d12c03048fab6e0cbc7571b779c592d610512 /nx-X11/programs/Xserver/xkb/xkbEvents.c
parentc0754a35755cdd4e25386abc6378e07605845948 (diff)
parentc8a5e33fcdde322f486d6c69e7e16fa346793fc9 (diff)
downloadnx-libs-abf3741362f4c200945db6403fcd54df6754d4af.tar.gz
nx-libs-abf3741362f4c200945db6403fcd54df6754d4af.tar.bz2
nx-libs-abf3741362f4c200945db6403fcd54df6754d4af.zip
Merge branch 'uli42-pr/various' into 3.6.x
Attributes GH PR #815: https://github.com/ArcticaProject/nx-libs/pull/815
Diffstat (limited to 'nx-X11/programs/Xserver/xkb/xkbEvents.c')
-rw-r--r--nx-X11/programs/Xserver/xkb/xkbEvents.c37
1 files changed, 14 insertions, 23 deletions
diff --git a/nx-X11/programs/Xserver/xkb/xkbEvents.c b/nx-X11/programs/Xserver/xkb/xkbEvents.c
index c7a0f9e87..791673753 100644
--- a/nx-X11/programs/Xserver/xkb/xkbEvents.c
+++ b/nx-X11/programs/Xserver/xkb/xkbEvents.c
@@ -804,21 +804,19 @@ XkbSrvInfoPtr xkbi;
xkbi= pXDev->key->xkbInfo;
if ( pClient->xkbClientFlags & _XkbClientInitialized ) {
-#ifdef DEBUG
if ((xkbDebugFlags&0x10)&&
((xE[0].u.u.type==KeyPress)||(xE[0].u.u.type==KeyRelease))) {
- ErrorF("XKbFilterWriteEvents:\n");
- ErrorF(" Event state= 0x%04x\n",xE[0].u.keyButtonPointer.state);
- ErrorF(" XkbLastRepeatEvent!=xE (0x%x!=0x%x) %s\n",
+ DebugF("XKbFilterWriteEvents:\n");
+ DebugF(" Event state= 0x%04x\n",xE[0].u.keyButtonPointer.state);
+ DebugF(" XkbLastRepeatEvent!=xE (0x%x!=0x%x) %s\n",
XkbLastRepeatEvent,xE,
((XkbLastRepeatEvent!=(void *)xE)?"True":"False"));
- ErrorF(" (xkbClientEventsFlags&XWDA)==0 (0x%x) %s\n",
+ DebugF(" (xkbClientEventsFlags&XWDA)==0 (0x%x) %s\n",
pClient->xkbClientFlags,
(_XkbWantsDetectableAutoRepeat(pClient)?"True":"False"));
- ErrorF(" !IsRelease(%d) %s\n",xE[0].u.u.type,
+ DebugF(" !IsRelease(%d) %s\n",xE[0].u.u.type,
(!_XkbIsReleaseEvent(xE[0].u.u.type))?"True":"False");
}
-#endif /* DEBUG */
if ( (XkbLastRepeatEvent==(void *)xE) &&
(_XkbWantsDetectableAutoRepeat(pClient)) &&
(_XkbIsReleaseEvent(xE[0].u.u.type)) ) {
@@ -853,13 +851,11 @@ XkbSrvInfoPtr xkbi;
if (xE[0].u.u.type == ButtonPress &&
((xE[0].u.keyButtonPointer.state >> 7) & button_mask) == button_mask &&
(xkbi->lockedPtrButtons & button_mask) == button_mask) {
-#ifdef DEBUG
/* If the MouseKeys is pressed, and the "real" mouse is also pressed
* when the mouse is released, the server does not behave properly.
* Faking a release of the button here solves the problem.
*/
- ErrorF("Faking release of button %d\n", xE[0].u.u.detail);
-#endif
+ DebugF("Faking release of button %d\n", xE[0].u.u.detail);
XkbDDXFakePointerButton(ButtonRelease, xE[0].u.u.detail);
}
}
@@ -868,19 +864,16 @@ XkbSrvInfoPtr xkbi;
for (i=0;i<nEvents;i++) {
type= xE[i].u.u.type;
-#ifdef DEBUG
if ((xkbDebugFlags&0x4)&&
((xE[0].u.u.type==KeyPress)||(xE[0].u.u.type==KeyRelease))) {
- XkbStatePtr s= &xkbi->state;
- ErrorF("XKbFilterWriteEvents (non-XKB):\n");
- ErrorF("event= 0x%04x\n",xE[0].u.keyButtonPointer.state);
- ErrorF("lookup= 0x%02x, grab= 0x%02x\n",s->lookup_mods,
- s->grab_mods);
- ErrorF("compat lookup= 0x%02x, grab= 0x%02x\n",
- s->compat_lookup_mods,
- s->compat_grab_mods);
+ DebugF("XKbFilterWriteEvents (non-XKB):\n");
+ DebugF("event= 0x%04x\n",xE[0].u.keyButtonPointer.state);
+ DebugF("lookup= 0x%02x, grab= 0x%02x\n",xkbi->state.lookup_mods,
+ xkbi->state.grab_mods);
+ DebugF("compat lookup= 0x%02x, grab= 0x%02x\n",
+ xkbi->state.compat_lookup_mods,
+ xkbi->state.compat_grab_mods);
}
-#endif
if ( (type>=KeyPress)&&(type<=MotionNotify) ) {
CARD16 old,new;
@@ -900,9 +893,7 @@ XkbSrvInfoPtr xkbi;
if (type == ButtonPress &&
((xE[i].u.keyButtonPointer.state >> 7) & button_mask) == button_mask &&
(xkbi->lockedPtrButtons & button_mask) == button_mask) {
-#ifdef DEBUG
- ErrorF("Faking release of button %d\n", xE[i].u.u.detail);
-#endif
+ DebugF("Faking release of button %d\n", xE[i].u.u.detail);
XkbDDXFakePointerButton(ButtonRelease, xE[i].u.u.detail);
}
}