WIP: _calculateCanvasSize outputs are floored, but imageSmoothingEnabled is still initalized on resize

This commit is contained in:
Yochay Doutsh 2019-02-06 16:04:33 +02:00
parent 869a3f6a13
commit 578ff36a06

View File

@ -686,8 +686,9 @@ $.Drawer.prototype = {
var pixelDensityRatio = $.pixelDensityRatio;
var viewportSize = this.viewport.getContainerSize();
return {
x: viewportSize.x * pixelDensityRatio,
y: viewportSize.y * pixelDensityRatio
// canvas width and height are integers
x: Math.floor(viewportSize.x * pixelDensityRatio),
y: Math.floor(viewportSize.y * pixelDensityRatio)
};
},