mbostock/d3 — pull request #1055 by darwin (2013-02-05 20:09:51+00:00)
Title: Allow custom coordinate space while dragging

Problem: when you modify grandparent's transform during drag callback you get discontinuity in d3.event data. This leads to poor experience during dragging as described here: http://stackoverflow.com/questions/13078535/stuttering-drag-when-using-d3-behavior-drag-and-transform

Solution: allow specification of custom node which will be taken as base coordinate space for the drag session.

In our case of modification grandparent's transform, this usage fixes the issue:

d3.behavior.drag().base(function(target) { return target.parentNode.parentNode; });