-
Notifications
You must be signed in to change notification settings - Fork 142
Closed
Description
Hello,
I'm trying to implement a filter that would circumvent execution of touchmove.zoom event and I noticed in the source code that the touchmoved method does not do
if (!filter.apply(this, arguments)) return;
The obvious question is why? Will something break if make this change? So far it works fine.
The reason I want to do this is because I want zoom to only handle multi touch events and let the single touch bubble up to the browser, so that the user can still scroll the page with one finger and zoom/pan with two fingers. So then the filter can be something like
d3
.zoom()
.filter(() => {
return !(d3.event.type === 'touchmove' && d3.event.touches.length <= 1);
})
Thanks
whoisjordangarcia, donmccurdy, valgussev, hohlb, Herst and 2 more
Metadata
Metadata
Assignees
Labels
No labels