[PATCH 01/18] Add Clickpad support

Henrik Rydberg rydberg at euromail.se
Sat Oct 9 00:29:44 PDT 2010


Hi Takashi,

> diff --git a/src/eventcomm.c b/src/eventcomm.c
> index 85dfd09..fc5055b 100644
> --- a/src/eventcomm.c
> +++ b/src/eventcomm.c
> @@ -269,6 +269,12 @@ event_query_axis_ranges(InputInfoPtr pInfo)
>  	}
>  
>  	xf86Msg(X_PROBED, "%s: buttons:%s\n", pInfo->name, buf);
> +
> +	/* clickpad device reports only the single left button mask */
> +	if (priv->has_left && !priv->has_right && !priv->has_middle && !priv->has_double) {
> +	    priv->is_clickpad = TRUE;
> +	    xf86Msg(X_PROBED, "%s: is Clickpad device\n", local->name);
> +	}
>      }
>  }


The variable has_double is true when the kernel reports multiple fingers via the
BTN_*TAP keys. This is the case for the macbook pads, and I would imagine it to
be true also for the clickpad soon. The clicking-on-lower-portion-of-pad is
interesting for both devices. In other words, perhaps the logic should be
reiterated?

Cheers,
Henrik


More information about the xorg-devel mailing list