Say you've defined a zoom behavior:
var zoom = d3.behavior.zoom().on('zoom', update);
When you apply the zoom behavior to a selection, you can unregister the event listeners that it uses internally to detect and respond to certain interactions. In your case, you'd want to do something like this:
selection.call(zoom)
.on("mousedown.zoom", null)
.on("touchstart.zoom", null)
.on("touchmove.zoom", null)
.on("touchend.zoom", null);
I'm not sure you want to remove the touch events. Doing so might eliminate double tap zooming. You should experiment with those.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…