diff --git a/src/kiri-mode/cam/client.js b/src/kiri-mode/cam/client.js index a423e247..e819ce19 100644 --- a/src/kiri-mode/cam/client.js +++ b/src/kiri-mode/cam/client.js @@ -477,7 +477,9 @@ CAM.init = function(kiri, api) { } } if (moto.space.info.mob) { + let touched = false; el.ontouchstart = (ev) => { + touched = true; if (poppedRec === rec && popped) { onLeave(ev); } else { @@ -486,6 +488,12 @@ CAM.init = function(kiri, api) { }; el.ontouchmove = onDown; el.onmouseenter = (ev) => { + if (touched) { + // touches block mouse events on touchscreen PCs + // which are often sent along with touch events + // but when not touched, allow the mouse to work + return; + } el.onmousedown = onDown; el.onmouseleave = onLeave; onEnter(ev);