Closed grubbychicken closed 7 years ago
The hammer event to bind to is panmove - $zimg.on("panmove", function...). However, something to consider with touch is how will you distinguish between when the crosshair should be tracking the finger and when the image should be panned/dragged? You can disable dragging with the widget dragable option.
Great, thanks. I'll give it a go!
Hi Wayne, thanks for helping me implement the crosshair last week. I am trying to get this to work on mobile too. A few problems I am running in to:
-the crosshair is only placed on the image when the user taps the screen. I'd really like the user to be able to run their finger across their screen and the crosshair follow their finger. When the user removes their finger from the screen my
#c1
div should be set with the coordinates (as in myonClick
event below. Do you think this is possible with hammer.js? Is this a 'touchmove' event?-my crosshairs don't follow the view as the page is scrolled.
I'd really appreciate your help with this. Thanks!