-
Notifications
You must be signed in to change notification settings - Fork 168
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multi-touch zoom not working on hybrid laptop #53
Comments
Is this on http://arose.github.io/ngl/, if not does it work there? Does it work on this site http://threejs.org/examples/#misc_controls_trackball? Are there any messages in the browser console? |
It doesn't work on the three.js site and there are no console errors. The problem is basically that the system defaults to page zooming when you use multitouch zoom. I just discovered zooming out works (because the page cannot be zoomed out any more, so zooming the canvas is working again). You have to block the event from propagating to other elements/prevent the default action (e.g. |
Thanks @hermanbergwerf added some |
Unfortunately it did not work. I shortly looked into it and this oneliner solves the issue. document.getElementById('viewport').addEventListener('touchmove',function(e){e.preventDefault();}); Preventing on scoll is probably not working since multitouch zoom is not considered a scroll event by the browser. You should block the propagation of |
Cool, I add that later today. Thanks! On Tue, Mar 15, 2016, at 11:30 AM, Herman Bergwerf wrote:
Links: |
Yep, fixed now (on my Chromebook). Awesome! |
I have a Chromebook with both a touch screen and a touchpad. I can zoom using my touchpad but not using multi-touch on the touch screen.
The text was updated successfully, but these errors were encountered: