tinypilot icon indicating copy to clipboard operation
tinypilot copied to clipboard

Handle touch events on touchscreen devices

Open ksherwood02 opened this issue 4 years ago • 7 comments

When using a mobile device (Chrome on Android, Chrome or Safari on iOS13) only the initial input is registered. I'd love to contribute and I'll start digging in to this if I can, but I'm sure others would benefit from this too.

ksherwood02 avatar Sep 23 '20 18:09 ksherwood02

Thanks for filing this, @ksherwood02! Can you share more details? I'm not sure what you mean when you say "only the initial input is registered."

Support for input from mobile devices was only added this morning (#266). Are you using the latest version?

mtlynch avatar Sep 23 '20 18:09 mtlynch

If I bring up MS Paint, as an example app so I can see where the cursor is, anywhere I touch the cursor moves, so it's registered the touch, but not the "click." Beyond that, I can't drag my finger across the screen to indicate the mouse has moved either. As I think about it, converting from a touch interface - deciding what is a click, a move, a click/drag, etc., will probably be a bit more involved.

When I use Chrome on Android, it registers a point being dropped where I touch. When I use Chrome on an iPad, it moves the curosr w/o placing a dot. The dots are from controlling it through Android.

[cid:88838f39-d603-44ba-9cf0-3f65ee9ae3f5]

Thanks, Kevin


From: Michael Lynch [email protected] Sent: Wednesday, September 23, 2020 2:27 PM To: mtlynch/tinypilot [email protected] Cc: ksherwood02 [email protected]; Mention [email protected] Subject: Re: [mtlynch/tinypilot] Add support for mobile devices as clients (#270)

Thanks for filing this, @ksherwood02https://github.com/ksherwood02! Can you share more details? I'm not sure what you mean when you say "only the initial input is registered."

Support for input from mobile devices was only added this morning (#266https://github.com/mtlynch/tinypilot/pull/266). Are you using the latest version?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/mtlynch/tinypilot/issues/270#issuecomment-697842594, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ARDWFDYFGLTR4EBVCAT5EP3SHI4YNANCNFSM4RXLRUMA.

ksherwood02 avatar Sep 23 '20 18:09 ksherwood02

Ah, gotcha. Someone started working on this in #192 but then work stopped. It doesn't look like it'd be too much work to get touch events working.

mtlynch avatar Sep 24 '20 14:09 mtlynch

A user on the forum has a use case that would take advantage of touch screen input (accessing the TinyPilot web interface remotely using Tailscale on a smartphone).

db39 avatar Jan 24 '23 15:01 db39

Some potentially useful info: Firefox's responsive mode has a 'touch simulation' option which could be very useful for testing touch functionality on desktop.

db39 avatar Feb 09 '23 17:02 db39

Adding references to some draft PRs around this that never got merged:

https://github.com/tiny-pilot/tinypilot/pull/1387 https://github.com/tiny-pilot/tinypilot/pull/1385

mtlynch avatar Sep 21 '23 14:09 mtlynch

Another user on the forum is also interested in touch screen support.

db39 avatar Jan 15 '24 12:01 db39

We explored this feature with a proof-of-concept branch, and it appears that there is some complexity if we wanted to achieve full-blown touch support.

So for the first step (this ticket), we un-break the touch experience, and support single left clicks.

We then split out two follow-up tickets for iterating on touch support:

  • https://github.com/tiny-pilot/tinypilot/issues/1781
  • https://github.com/tiny-pilot/tinypilot/issues/1782

jotaen4tinypilot avatar Apr 11 '24 19:04 jotaen4tinypilot