Firefox has stopped showing the touch buttons when running on a Windows system with touch support. Tested with Firefox 69 on our Windows 10 laptop. It must have worked at some point as bug 6348 had issues with the keyboard button with Firefox on Windows. Also note bug 5882 which had the same issue but for Edge.
Check bug 6348 after fixing this as it can most likely be closed.
Firefox apparently had problems last time upstream changed the touch detection: https://github.com/novnc/noVNC/pull/650 Might have been an issue for a long time.
Touch support completely disabled. Seems to be a bug in Firefox as older versions work. Latest working is Firefox 66. Filed a bug upstream: https://bugzilla.mozilla.org/show_bug.cgi?id=1587760
So upstream has gotten back to us with the fact that this is intentional. Apparently they see a huge problem with sites assuming that touch means mobile and make the site difficult to use on a desktop machine. Their solution is to surrender the TouchEvent API to the mobile only domain, and sites that want touch on desktop need to use the newer PointerEvent API. So I guess we'll have to have a look at that. Most browsers support it (even IE!), but unfortunately Safari only does in the latest version. So we probably need to keep some backwards compatibility. They also claim that Chrome and Edge will also follow this behaviour. Safari is unknown, but touch on macOS doesn't seem to be a big thing anyway.
Upstream also claims that we can get the old behaviour back by setting: dom.w3c_touch_events.enabled = 1 dom.w3c_touch_events.legacy_apis.enabled = true
(In reply to comment #4) > They also claim that Chrome and Edge will also follow this behaviour. Safari is > unknown, but touch on macOS doesn't seem to be a big thing anyway. Chrome on Unix (touch) seems to follow this behavior now also.
This PR upstream also affects the touch handing and needs to be considered: https://github.com/novnc/noVNC/pull/1346
The touch detection is still broken on Firefox 69. These touch events suddenly now works again on Firefox 74 on both windows 10 laptop and desktop.
Filed a question upstream asking if this works as intended or if the recommended way of supporting touch and mouse across all types of devices is still via pointer events. This is described in MDN web docs, and I suspect this still holds true. (https://developer.mozilla.org/en-US/docs/Web/API/Touch_events) Wrote the question in the upstream bug I opened a while ago: https://bugzilla.mozilla.org/show_bug.cgi?id=1587760 and on the related bug thread: https://bugzilla.mozilla.org/show_bug.cgi?id=1412485
There is still some uncertainties with this from uppstream but what I can discern is: - The removed legacy support is referring to 'ontouch' and createEvent('TouchEvent') etc. - addEventListener() with touchstart etc. is still usable. (Works in current Firefox and it is intended) Haven't got any answer yet if this will go away or not. - Pointer events is recommended by Mozilla and MDN. - Chrome have done the change to remove 'ontouch' and keep addEventListener while also supporting pointerEvents. So what I can see is that we can pretty much keep using our code as is, as long Mozilla does not intend to remove addEventListener('touchstart') etc. in the near future. Still waiting for answer from upstream though.
Mozilla has backed on the changes that caused the problems in this issue, namely the removal of addEventListener('touchstart') support. Due to this revert the touch now works in Firefox as it should. Still waiting for response from upstream, but this issue seems to be fixed.