[PATCH 04/20] mi: simplify a "check for keyboard" condition

Daniel Stone daniel at fooishbar.org
Mon May 2 18:22:17 PDT 2011


On Fri, Feb 18, 2011 at 01:52:11PM +1000, Peter Hutterer wrote:
> Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>
> ---
>  mi/mipointer.c |    3 +--
>  1 files changed, 1 insertions(+), 2 deletions(-)
> 
> diff --git a/mi/mipointer.c b/mi/mipointer.c
> index 124f9de..aa0ca6d 100644
> --- a/mi/mipointer.c
> +++ b/mi/mipointer.c
> @@ -193,8 +193,7 @@ miPointerDisplayCursor (DeviceIntPtr pDev, ScreenPtr pScreen, CursorPtr pCursor)
>      miPointerPtr pPointer;
>  
>      /* return for keyboards */
> -    if ((IsMaster(pDev) && !DevHasCursor(pDev)) ||
> -        (!IsMaster(pDev) && pDev->u.master && !DevHasCursor(pDev->u.master)))
> +    if (!IsPointerDevice(pDev))
>              return FALSE;
>  
>      pPointer = MIPOINTER(pDev);

This is a change in semantics; is it safe? If so, please note in the
commit message.

Cheers,
Daniel
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.x.org/archives/xorg-devel/attachments/20110503/52f86667/attachment.pgp>


More information about the xorg-devel mailing list