Is it possible to trigger the copy/paste context menu from the System app
by passing touch events to HTMLIFrameElement.sendTouchEvent
<https://developer.mozilla.org/en-US/docs/Web/API/HTMLIFrameElement/sendTouchEvent>
?

Sending 'touchstart' and/or 'mousedown' events does not trigger the menu;
it seems `sendTouchEvent` doesn't produce any meaningful selection events
otherwise. (Our marionette tests are able to produce this context menu, but
I presume that's through a different codepath.) I'm admittedly unfamiliar
with how input events flow through Gecko to produce this menu, and my
dxr-fu isn't great.

Additional context: I'd like to intercept touch events (which works) and
pass them onto the appropriate element/iframe (which works, in general),
but I haven't been able to figure out how to forward the long-press gesture
that triggers the copy/paste menu. This is relevant for the incoming
native utility
tray enhancements <https://bugzilla.mozilla.org/show_bug.cgi?id=1178162>.

Any pointers or tips would be appreciated. Based on what I've seen so far,
it appears that this isn't possible as-is.


Marcus
_______________________________________________
dev-fxos mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-fxos

Reply via email to