Merge branch 'P5-1859_panorama_canvas_breaks'

This commit is contained in:
sofiekedvik
2017-11-08 10:01:25 +01:00
8 changed files with 5347 additions and 5 deletions
+1
View File
@@ -63,6 +63,7 @@ var Canvas = fabric.util.createClass(fabric.Canvas, {
this.getViewport().reset();
}
this.sendToBack(this.getImage());
this.getImage().center();
this.getDragbars().resetPosition();
this.renderAll();
},
+2 -2
View File
@@ -86,7 +86,7 @@ function DragbarHandler(canvas) {
_dragbars.x = new fabric.Rect($.extend({}, config.dragBar, {
axis: 'x',
width: canvas.getImage().width,
width: canvas.getImage().width * canvas.getImage().scaleY,
height: config.dragBar.size,
lockMovementY: true,
selectable: true,
@@ -99,7 +99,7 @@ function DragbarHandler(canvas) {
_dragbars.y = new fabric.Rect($.extend({}, config.dragBar, {
axis: 'y',
width: config.dragBar.size,
height: canvas.getImage().height,
height: canvas.getImage().height * canvas.getImage().scaleY,
lockMovementX: true,
selectable: true,
hoverCursor: 'ns-resize',