javascript - iScroll 4 No Canvas click/tap events when zoomed in -


i have odd problem can't work out - i'm using iscroll 4 scroll html5 canvas (implemented below):

mapscroll = new iscroll('td_map',  {zoom: true, bounce: false,                                             hscrollbar: false, vscrollbar: false,                                 }, 100); 

the zoom works brilliantly (tested on ipad 2/4), , canvas items have tap , click events firing when map not zoomed in. zoom used (so in iscroll scale changed minzoom of 1) click events aren't firing or they're not being reached. if zoom out or double click reset zoom normal, events fire expected again.

the click event:

traingroup.on("click tap", function(evt) {     console.log("hello train!");  }); 

any ideas what's going on great :)

thanks much, becky

edit: after debug logging work out going on where, looks mouse event has wrong information. seems css transform zoom on canvas doesn't update mouse clicks, when think i'm clicking on object clicking whatever on non-zoomed canvas. haven't figured out how update mouse events translated info yet, @ least thats progress :)


Comments

Popular posts from this blog

matlab - Deleting rows with specific rules -

jquery - How would i go about shortening this code? And to cancel the previous click on click of new section? -