I have a div with id="inn" and then a code like this:
var zin = document.querySelector("div#inn");
zin.addEventListener("click", function(e){
if (count <= maxzoom) {
startZoomIn();
}
})
The crazy trouble is that, if I click with mouse, all works fine, but if I use (as needed) the over cursor (I'm workin' with Leap Motion), it don't work, it seems isn't recognized... The very strange thing is that an absolutely equal code, for different element, works perfectly; and that, exactly the same code works fine on a different page...
I'm workin' around this trouble by many hours, and maybe are stultyfied..., but in any way I try to approach to solve, the trouble stay always there...
Just had a quick loop at the Leap Motion JS Reference and it looks like you need to handle gestures (such as click differently)
Additionally, you might find LeapCursor.js helpful. It should make it easier for you to do something like: