[PATCH xf86-input-synaptics 10/12] Add right button area property
Chase Douglas
chase.douglas at canonical.com
Wed Feb 22 20:30:31 PST 2012
On 02/22/2012 07:58 PM, Peter Hutterer wrote:
> On Thu, Feb 09, 2012 at 06:53:04PM -0800, Chase Douglas wrote:
>> Some clickpad devices have a right button area painted on them. Set this
>> property to the area of the right button to enable right click actions
>> when tapping or clicking in this area.
>>
>> Signed-off-by: Chase Douglas<chase.douglas at canonical.com>
>> ---
>> include/synaptics-properties.h | 3 ++
>> man/synaptics.man | 45 ++++++++++++++++++++++++++++++++++++++++
>> src/properties.c | 21 ++++++++++++++++++
>> src/synaptics.c | 28 ++++++++++++++++++++++++-
>> src/synapticsstr.h | 1 +
>> 5 files changed, 97 insertions(+), 1 deletions(-)
>>
>> diff --git a/include/synaptics-properties.h b/include/synaptics-properties.h
>> index 712a10b..0a253b2 100644
>> --- a/include/synaptics-properties.h
>> +++ b/include/synaptics-properties.h
>> @@ -161,6 +161,9 @@
>> /* 32 bit, 4 values, left, right, top, bottom */
>> #define SYNAPTICS_PROP_AREA "Synaptics Area"
>>
>> +/* 32 bit, 4 values, left, right, top, buttom */
>> +#define SYNAPTICS_PROP_RIGHTBUTTON_AREA "Synaptics Right Button Area"
>> +
>
> AFAIK, some devices have a middle button painted on too, so this needs to be
> more flexible.
Are you sure? I've never seen any.
I was thinking that we could add middle button support later by
providing SYNAPTICS_PROP_MIDDLEBUTTON_AREA if we needed to.
I'm not a big fan of cramming a ton of somewhat unrelated data into the
same device property. As an example, I think the tap action property
should have been split up as "tap action areas" and "tap action count"
or something like that.
> How about a property that takes sets of 4 coordinates for
> each button, with the driver deciding whether it's the right button or right
> + middle based on the number of values in the property?
Can properties have variable numbers of coordinates? I'm unaware of any
properties like this today. I think it would be less discoverable as
well, and is unrelated enough to warrant another property. We aren't
hurting for property value space are we?
-- Chase
More information about the xorg-devel
mailing list