xkb: Unwrap properly in ProcessPointerEvent.
Instead of hardcoding CoreProcessPointerEvent, actually try to unwrap properly
and then call the unwrapped processInputProc. Seems to be a better idea,
especially since it makes stuff actually work...
(cherry picked from commit 8f9bf927e1
)
This commit is contained in:
parent
d3588a0aee
commit
ee3aa948eb
|
@ -692,6 +692,8 @@ ProcessPointerEvent( register xEvent * xE,
|
||||||
DeviceIntPtr dev = (DeviceIntPtr)LookupKeyboardDevice();
|
DeviceIntPtr dev = (DeviceIntPtr)LookupKeyboardDevice();
|
||||||
XkbSrvInfoPtr xkbi = dev->key->xkbInfo;
|
XkbSrvInfoPtr xkbi = dev->key->xkbInfo;
|
||||||
unsigned changed = 0;
|
unsigned changed = 0;
|
||||||
|
ProcessInputProc backupproc;
|
||||||
|
xkbDeviceInfoPtr xkbPrivPtr = XKBDEVICEINFO(mouse);
|
||||||
|
|
||||||
xkbi->shiftKeyCount = 0;
|
xkbi->shiftKeyCount = 0;
|
||||||
xkbi->lastPtrEventTime= xE->u.keyButtonPointer.time;
|
xkbi->lastPtrEventTime= xE->u.keyButtonPointer.time;
|
||||||
|
@ -703,7 +705,26 @@ unsigned changed = 0;
|
||||||
xkbi->lockedPtrButtons&= ~(1<<(xE->u.u.detail&0x7));
|
xkbi->lockedPtrButtons&= ~(1<<(xE->u.u.detail&0x7));
|
||||||
changed |= XkbPointerButtonMask;
|
changed |= XkbPointerButtonMask;
|
||||||
}
|
}
|
||||||
CoreProcessPointerEvent(xE,mouse,count);
|
|
||||||
|
/* Guesswork. mostly.
|
||||||
|
* xkb actuall goes through some effort to transparently wrap the
|
||||||
|
* processInputProcs (see XkbSetExtension). But we all love fun, so the
|
||||||
|
* previous XKB implementation just hardcoded the CPPE call here instead
|
||||||
|
* of unwrapping like anybody with any sense of decency would do.
|
||||||
|
* I got no clue what the correct thing to do is, but my guess is that
|
||||||
|
* it's not hardcoding. I may be wrong. whatever it is, don't come whining
|
||||||
|
* to me. I just work here.
|
||||||
|
*
|
||||||
|
* Anyway. here's the old call, if you don't like the wrapping, revert it.
|
||||||
|
*
|
||||||
|
* CoreProcessPointerEvent(xE,mouse,count);
|
||||||
|
*
|
||||||
|
* see. it's still steaming. told you. (whot)
|
||||||
|
*/
|
||||||
|
UNWRAP_PROCESS_INPUT_PROC(mouse, xkbPrivPtr, backupproc);
|
||||||
|
mouse->public.processInputProc(xE, mouse, count);
|
||||||
|
COND_WRAP_PROCESS_INPUT_PROC(mouse, xkbPrivPtr,
|
||||||
|
backupproc, xkbUnwrapProc);
|
||||||
|
|
||||||
xkbi->state.ptr_buttons = mouse->button->state;
|
xkbi->state.ptr_buttons = mouse->button->state;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue