mirror of
https://github.com/Hopiu/fabric.js.git
synced 2026-05-24 05:03:44 +00:00
JSHint
This commit is contained in:
parent
9dc2eaa658
commit
ec0dcbfeb0
2 changed files with 3 additions and 9 deletions
|
|
@ -46,10 +46,8 @@ fabric.util.object.extend(fabric.Object.prototype, /** @lends fabric.Object.prot
|
||||||
getSvgTransform: function() {
|
getSvgTransform: function() {
|
||||||
var toFixed = fabric.util.toFixed,
|
var toFixed = fabric.util.toFixed,
|
||||||
angle = this.getAngle(),
|
angle = this.getAngle(),
|
||||||
center = this.getCenterPoint(),
|
vpt = this.getViewportTransform(),
|
||||||
vpt = this.getViewportTransform();
|
center = fabric.util.transformPoint(this.getCenterPoint(), vpt),
|
||||||
|
|
||||||
center = fabric.util.transformPoint(center, vpt);
|
|
||||||
|
|
||||||
NUM_FRACTION_DIGITS = fabric.Object.NUM_FRACTION_DIGITS,
|
NUM_FRACTION_DIGITS = fabric.Object.NUM_FRACTION_DIGITS,
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -596,17 +596,13 @@
|
||||||
* @chainable true
|
* @chainable true
|
||||||
*/
|
*/
|
||||||
absolutePan: function (point) {
|
absolutePan: function (point) {
|
||||||
var wh = fabric.util.transformPoint(
|
|
||||||
new fabric.Point(this.getWidth(), this.getHeight()),
|
|
||||||
this.viewportTransform
|
|
||||||
);
|
|
||||||
this.viewportTransform[4] = -point.x;
|
this.viewportTransform[4] = -point.x;
|
||||||
this.viewportTransform[5] = -point.y;
|
this.viewportTransform[5] = -point.y;
|
||||||
this.renderAll();
|
this.renderAll();
|
||||||
for (var i = 0, len = this._objects.length; i < len; i++) {
|
for (var i = 0, len = this._objects.length; i < len; i++) {
|
||||||
this._objects[i].setCoords();
|
this._objects[i].setCoords();
|
||||||
}
|
}
|
||||||
return this
|
return this;
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue