drag and drop operatons now dynamically generate a temporary top layer for high performance drag and drop. When completed, the top layer is removed. Also cleaned up a bit of drag and drop logic

This commit is contained in:
Eric Rowell
2012-12-30 23:14:23 -08:00
parent 36584a3ce2
commit 7ba40a6a68
7 changed files with 130 additions and 81 deletions

View File

@@ -150,8 +150,6 @@
/**
* apply shadow
* @name applyShadow
* @param {CanvasContext} context
* @param {Function} func draw function
* @methodOf Kinetic.Canvas.prototype
* @param {Kinetic.Shape} shape
* @param {Function} drawFunc
@@ -194,6 +192,13 @@
pixelRatio = 1 / pixelRatio;
this.getContext().scale(pixelRatio, pixelRatio);
}
},
_applyAncestorTransforms: function(node) {
var context = this.context;
node.eachAncestorReverse(function(no) {
var t = no.getTransform(), m = t.getMatrix();
context.transform(m[0], m[1], m[2], m[3], m[4], m[5]);
});
}
};