Switching screens relies on rootx/y to be set to the correct value. Though we technically take a mask for GetKeyboardEvents we don't actually handle it properly anyway, so this hack is acceptable for now. This should really be shared code with GPE but not today.
Signed-off-by: Peter Hutterer <[email protected]> --- dix/getevents.c | 10 ++++++++++ 1 files changed, 10 insertions(+), 0 deletions(-) diff --git a/dix/getevents.c b/dix/getevents.c index 08c6269..33847d0 100644 --- a/dix/getevents.c +++ b/dix/getevents.c @@ -1033,6 +1033,16 @@ GetKeyboardEvents(InternalEvent *events, DeviceIntPtr pDev, int type, set_valuators(pDev, event, &mask); + /* FIXME: this should really be common code with GetPointerEvents */ + if (!IsFloating(pDev)) { + DeviceIntPtr master = GetMaster(pDev, MASTER_POINTER); + + event->root_x = master->last.valuators[0]; + event->root_y = master->last.valuators[1]; + event->root_x_frac = master->last.remainder[0]; + event->root_y_frac = master->last.remainder[0]; + } + return num_events; } -- 1.7.6 _______________________________________________ [email protected]: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: http://lists.x.org/mailman/listinfo/xorg-devel
