Simulating touch messages on desktop - what do the smart kids do?
J. Landman Gay
jacque at hyperactivesw.com
Mon Feb 13 14:17:42 EST 2012
On 2/13/12 1:04 PM, Ben Rubinstein wrote:
> I tried simply adding mouseDown/Up/Move/Release handlers that called the
> corresponding touch handlers, but that didn't seem to be a complete
> solution (not exactly sure why not, but I did this to a stack that was
> working on iOS, and it went awry...). And in any case, that would help
> for the simple case of a single touch at a time, but not for the more
> interesting ones involving multi-touch gestures, or overlapping touches.
>
> So my question: what do the smart kids do to speed up their development
> in this case?
I used to do it your way -- passing touch messages to mouse messages
after checking the environment. When we were writing the teaching stack
for the conference, Mark Waddingham suggested we just ditch the touch
messages entirely and use only mouse messages. I've been doing that ever
since, it works fine. Touch messages are passed to mouse messages
automatically, so eliminating them also removes an extra message from
the hierarchy and avoids the problem of double messages entirely.
I've seen no differences in response times using only mouse messages.
--
Jacqueline Landman Gay | jacque at hyperactivesw.com
HyperActive Software | http://www.hyperactivesw.com
More information about the use-livecode
mailing list