From 378c2a160c578c5fa182a6363dbc3ebf787189c2 Mon Sep 17 00:00:00 2001 From: yellowtailfan <36425185+yellowtailfan@users.noreply.github.com> Date: Fri, 19 Apr 2019 16:19:46 +1000 Subject: [PATCH] Fixed: window resize was resetting image smoothing. --- src/drawer.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/drawer.js b/src/drawer.js index 7c4a433a..0815ee50 100644 --- a/src/drawer.js +++ b/src/drawer.js @@ -253,12 +253,13 @@ $.Drawer.prototype = { this.canvas.height != viewportSize.y ) { this.canvas.width = viewportSize.x; this.canvas.height = viewportSize.y; + this._updateImageSmoothingEnabled(this.context); if ( this.sketchCanvas !== null ) { var sketchCanvasSize = this._calculateSketchCanvasSize(); this.sketchCanvas.width = sketchCanvasSize.x; this.sketchCanvas.height = sketchCanvasSize.y; + this._updateImageSmoothingEnabled(this.sketchContext); } - this._updateImageSmoothingEnabled(this.context); } this._clear(); }