pinch zoom

66 views
Skip to first unread message

ravi swami

unread,
Jan 17, 2022, 12:22:00 AM1/17/22
to dev-we...@mozilla.org

Hi Team,


Currently I am trying to simulate touch actions such as pinch, scroll, using the pointer events. I went through some of the marionette driver scripts: legacy_actions.py and gestures.py (even these are deprecated scripts) and found the algorithm for pinch method, followed the same algorithm while defining pinch method using pointer events.


Tested and observed that it is only selecting the content present between the two touch points, not zooming in/out. As I am a novice here, not clear whether I missed something or not. Please check and give your valuable comments.

Message has been deleted
Message has been deleted
Message has been deleted
Message has been deleted

Henrik Skupin

unread,
Jan 28, 2022, 8:06:31 AM1/28/22
to Rajapriya Radhakrishnan, dev-we...@mozilla.org, rav...@gmail.com
Rajapriya Radhakrishnan wrote on 26.01.22 17:12:

> Like context menu action, we are trying to simulate pinch-zoom in/out
> action using pointer events, observed only dragging not zooming in &
> out. Please see the attachments.

This will not work at the moment given that "touch" support is not yet
implemented. You will have to wait until
https://bugzilla.mozilla.org/show_bug.cgi?id=1543337 will be fixed. It
won't hopefully take to long. So maybe CC yourself and observe the status.

> We found some pinch code from the deprecated file legacy_actions.py, and
> followed the same algorithm here while defining the pinch method using
> pointer events. Please confirm whether that algorithm is fine here too
> to simulate pinch action.

This won't work due to the reasons above. And also your script sets a
pointer type of `mouse` which is different to `touch` and cannot be used
for swiping and pinching.

Best,

--
Henrik Skupin
Staff Software Engineer
Mozilla Corporation
Message has been deleted
Message has been deleted

Henrik Skupin

unread,
Mar 9, 2022, 9:31:10 AM3/9/22
to Rajapriya Radhakrishnan, dev-we...@mozilla.org, rav...@gmail.com
Rajapriya Radhakrishnan wrote on 09.03.22 10:59:

> For the pinch and swipe actions, I hope the touch pointer is supported
> now. Recently I took the latest version - 99.0b1 (ftp path -
> _https://ftp.mozilla.org/pub/firefox/releases/99.0b1/linux-x86_64/en-US/firefox-99.0b1.tar.bz2
> <https://ftp.mozilla.org/pub/firefox/releases/99.0b1/linux-x86_64/en-US/firefox-99.0b1.tar.bz2>_)
> and tried to send pinch action and still observing the touch error i.e.,
> /marionette_driver.errors.InvalidArgumentException: Unknown pointerType:
> [object String] "touch". /
>
> Not sure which version I need to take. Please advise.

No, as you have seen it's not supported yet. If you want to follow the
status please check the following bug:

Henrik Skupin

unread,
Mar 9, 2022, 9:31:37 AM3/9/22
to Rajapriya Radhakrishnan, dev-we...@mozilla.org, rav...@gmail.com
Henrik Skupin wrote on 09.03.22 15:31:
https://bugzilla.mozilla.org/show_bug.cgi?id=1543337

Rajapriya Radhakrishnan

unread,
May 31, 2022, 8:19:05 AM5/31/22
to dev-we...@mozilla.org, hsk...@mozilla.com, rav...@gmail.com, rajapri...@gmail.com
switching to my new mail id rajapr...@gmail.com because of some log-in issues with my existing email id - rajapri...@gmail.com.

Rajapriya Radhakrishnan

unread,
May 31, 2022, 9:09:37 AM5/31/22
to dev-we...@mozilla.org, Rajapriya Radhakrishnan, hsk...@mozilla.com, rav...@gmail.com
Removing my old mail id - rajapri...@gmail.com.
Reply all
Reply to author
Forward
0 new messages