[PATCH xf86-input-synaptics 6/6] Switch X and Y axis labels to "Abs {X,Y}"

Peter Hutterer peter.hutterer at who-t.net
Wed Jan 25 22:07:00 PST 2012


On Thu, Jan 19, 2012 at 01:05:51PM -0800, Chase Douglas wrote:
> Non-raw X core and XI events are provided in absolute coordinates. If
> you really care, you can look at the XI axis class for each axis to see
> if it's relative or absolute.

The definition of absolute/relative in X is a mess. Synaptics, in the
default use, still technically uses relative axis since all we do, most of
the time, is send relative events to the server.

Yes, the underlying axis itself is absolute, but we calculate the delta
depending on the device mode. What benefit does this change give us?

Cheers,
  Peter
> 
> Switching this label to absolute makes more sense when touch data is
> sent through it as well.
> 
> Signed-off-by: Chase Douglas <chase.douglas at canonical.com>
> ---
>  src/synaptics.c |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/src/synaptics.c b/src/synaptics.c
> index 1d963cb..34915a2 100644
> --- a/src/synaptics.c
> +++ b/src/synaptics.c
> @@ -955,9 +955,9 @@ static void InitAxesLabels(Atom *labels, int nlabels,
>              labels[2] = XIGetKnownProperty(AXIS_LABEL_PROP_REL_HSCROLL);
>  #endif
>          case 2:
> -            labels[1] = XIGetKnownProperty(AXIS_LABEL_PROP_REL_Y);
> +            labels[1] = XIGetKnownProperty(AXIS_LABEL_PROP_ABS_Y);
>          case 1:
> -            labels[0] = XIGetKnownProperty(AXIS_LABEL_PROP_REL_X);
> +            labels[0] = XIGetKnownProperty(AXIS_LABEL_PROP_ABS_X);
>              break;
>      }
>  
> -- 
> 1.7.8.3


More information about the xorg-devel mailing list