[PATCH] dix: auto-float SD's with SendCoreEvents "false"

Daniel Stone daniel at fooishbar.org
Mon Sep 7 19:56:59 PDT 2009


Hi,

On Tue, Sep 08, 2009 at 10:09:43AM +1000, Peter Hutterer wrote:
> AlwaysCore and SendCoreEvents specify whether a device is to send core
> events. A device that has either disabled is not supposed to send core
> events.
> 
> With MPX/XI2, a device that is attached automatically sends core events when
> the event is routed through the master device. Floating a slave device
> disables core events by breaking the route.
> 
> This patch automatically floats devices that have coreEvents disabled in the
> xorg.conf/HAL. This replicates the behaviour of a SendCoreEvents "false"
> device in server 1.6 and earlier.
> 
> The devices may still be reattached to a master at runtime.
> 
> Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>

Acked-by: Daniel Stone <daniel at fooishbar.org>

(comment below)

> @@ -2357,7 +2360,13 @@ AttachDevice(ClientPtr client, DeviceIntPtr dev, DeviceIntPtr master)
>       */
>      if (!master)
>      {
> -        WindowPtr currentRoot = dev->spriteInfo->sprite->spriteTrace[0];
> +        WindowPtr currentRoot;
> +
> +        if (dev->spriteInfo->sprite)
> +            currentRoot = dev->spriteInfo->sprite->spriteTrace[0];
> +        else
> +            currentRoot = WindowTable[0];
> +
>          /* we need to init a fake sprite */
>          screen = currentRoot->drawable.pScreen;
>          screen->DeviceCursorInitialize(dev, screen);

Should this hnk go in as a separate fix though? Should we maybe just add
a GetDeviceSpriteWindow helper function that does this for us?

Cheers,
Daniel
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
Url : http://lists.x.org/archives/xorg-devel/attachments/20090908/bf990070/attachment.pgp 


More information about the xorg-devel mailing list