[PATCH] Always update master->u.lastSlave in mieqProcessDeviceEvent

Peter Hutterer peter.hutterer at who-t.net
Wed Jul 15 22:50:57 PDT 2009


On Tue, Jul 14, 2009 at 01:51:16PM +0200, Pierre Willenbrock wrote:
> This fixes pointer warping when using a scaled pointer input device(e.g.
> synaptics).
> 
> By the way, having the dev->u.master check only in the "we have no
> handler" branch looks strange.

right, this should be in both of course. Care to send me a patch?

> commit b765ceed81974c1ce2c54cca270689948452b2bd
> Author: Pierre Willenbrock <pierre at pirsoft.de>
> Date:   Tue Jul 14 13:42:19 2009 +0200
> 
>     Always update u.lastSlave
> 
> diff --git a/mi/mieq.c b/mi/mieq.c
> index 0f07b16..f050115 100644
> --- a/mi/mieq.c
> +++ b/mi/mieq.c
> @@ -390,17 +390,17 @@ mieqProcessDeviceEvent(DeviceIntPtr dev,
>      else {
>          master = CopyGetMasterEvent(dev, event, masterEvents);
>  
> +        if (master)
> +            master->u.lastSlave = dev;
> +
>          /* If someone's registered a custom event handler, let them
>           * steal it. */
>          if (handler)
>          {
>              handler(DequeueScreen(dev)->myNum, event, dev);
>              if (master)
> -            {
> -                master->u.lastSlave = dev;
>                  handler(DequeueScreen(master)->myNum,
>                          (InternalEvent*)masterEvents->event, master);
> -            }
>          } else
>          {
>              /* process slave first, then master */

ACK, can you please resend as a git-formatted patch? git am didn't like this
one.

Cheers,
  Peter


More information about the xorg-devel mailing list