Copy link to clipboard
Copied
Hi!
I'm developing an application for an interactive table running Windows 10 that has a menu with five buttons. Each button calls a popup window.
Each user should be able to pan and zoom his or her own window. All users panning and zooming all windows at the same time.
My problem is that when I use the simulator inside of Animate CC I can only pinch to zoom only one window. Even if I made the gesture above another window the scaling only applies to one of the windows.
I tried, inside of the handler function, using event.target and event.currentTarget but the result is the same.
What should I do?
Copy link to clipboard
Copied
Part of this could be your touch monitor. The HP TouchSmart I use at work, for instance, only sees two touch points - so only one person would be able to pinch zoom at a time... but maybe two people could drag an item. Different touch monitors support different numbers of points.
Also, I've had good luck in the past with this library:
Copy link to clipboard
Copied
Hi, @dmennenoh!
Thank you for the answer.
The only way I have here to test on a real device is by running Windows 10 on an iPad Pro using Duet Display.
And strangely... it WORKED.
I don't understand why I can't get pinch to zoom on different objects using the simulator...
Anyway. It's working now. Thank you!
Copy link to clipboard
Copied
I would suspect the simulator only copes with two fingers. But the general answer is that you should be tracking touchid, not current target. I mean, you have the listener on the target in question, but to know that the update you are getting belongs to the object you're interested in, you store the touchid on press, and check the touchid on any move event. Only pinch or zoom the object if the move event has the right touchid.