On Mon, Nov 8, 2010 at 7:31 AM, Chris Bagwell <ch...@cnpbagwell.com> wrote:
> On Sun, Nov 7, 2010 at 4:44 PM, Ping Cheng <pingli...@gmail.com> wrote:
>> On Sun, Nov 7, 2010 at 9:50 AM, Chris Bagwell <ch...@cnpbagwell.com> wrote:
>>> Please do not submit this 1 patch.  #2 is OK to submit still.
>>>
>>> I had forgot that tablet PC's/touchscreens only send BTN_TOUCH without
>>> a BTN_TOOL_FINGER.  So we should continue behaviour as treating
>>> BTN_TOUCH ~= BTN_TOOL_FINGER.
>>
>> I see your point. But I don't feel we want to treat BTN_TOUCH ~=
>> BTN_TOOL_FINGER. That is a bit confusion in our context - pen can send
>> BTN_TOUCH too.
>>
>> I would say we check for the existence of BTN_TOOL_DOUBLETAP. If it
>> does, the device is not PROTOCOL_GENERIC. Hence, TOOL_FINGER is
>> consider as PAD. As I mentioned before, we need to keep the
>> DOUBLETAP/TRIPLETAP and  TOOL_FINGER?PAD code as is since we have to
>> support backward compability (otherwise, I lose my job ;).
>>
>> It is very ugly, I agree. But, we can not do much about it.
>>
>> What do you think?
>>
>> Ping
>>
>
> I'll add something like above but I think the logic is slightly different.
>
> The code handles all the generic tablet and Wacom Protocol 4/5 cases
> just fine today.  The issue is limited to working with "generic
> touchpads" and "generic touchscreens" I think.    The later are the
> only ones that do not send BTN_TOOL_FINGER as best I know.  So I'll
> add something similar to evdev's EVDEV_TOUCHPAD and EVDEV_TOUCHSCREEN.
>
> Since this is same concept as knowing when to set relative vs.
> absolute mode, the flag WCM_LCD probably already has correct meaning.
>
> Roughly:
>
> case BTN_TOOL_FINGER:
> if (common->wcmProtocol != WCM_PROTOCOL_GENERIC)
>  /* this is PAD device on Wacom device.  Setup as PAD. */
> else
>  /* This is a generic touchpad in relative mode.  Setup like
> DOUBLETAP on a Wacom. We will ignore any accompanying BTN_TOUCH for
> setup phase. */
> break;
>
> case BTN_TOUCH:
> if (common->wcmProtocol == WCM_PROTOCOL_GENERIC &&
> TabletHasFeature(common, WCM_LCD)
>  /* This is a generic touchscreen in absolute mode.  Setup like
> DOUBLETAP on a Wacom. */
> else
>  /* This is touch sent with protocol 4/5 devices or with tochpads.
> Ignore during setup because it was setup with BTN_TOOL_* event. */
> break;

Good. Thank you for the clarification. I would like to see more people
test the new changes on different models.

TabletHasFeature(common, WCM_LCD) means the tablet is a display
tablet, which can be a Tablet PC (embedded) or Cintiq/PL tablet
(standalone). If absolute mode is what you are looking for, you get
what you need.

Ping

------------------------------------------------------------------------------
The Next 800 Companies to Lead America's Growth: New Video Whitepaper
David G. Thomson, author of the best-selling book "Blueprint to a 
Billion" shares his insights and actions to help propel your 
business during the next growth cycle. Listen Now!
http://p.sf.net/sfu/SAP-dev2dev
_______________________________________________
Linuxwacom-devel mailing list
Linuxwacom-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel

Reply via email to