From 0c6352e2760382ba67678755d379cc4d62650de8 Mon Sep 17 00:00:00 2001 From: Nathan Kunicki Date: Sun, 26 Nov 2017 17:59:43 +0000 Subject: [PATCH] Drawing after changing mode --- src/bittmappeditor.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/bittmappeditor.ts b/src/bittmappeditor.ts index 5bf81f3..f11c325 100644 --- a/src/bittmappeditor.ts +++ b/src/bittmappeditor.ts @@ -143,17 +143,20 @@ class BittMappEditor { public pencilMode () { this._selection = new Uint8Array((this._width / 8) * this._height); this._editorMode = Mode.PENCIL; + this._redraw(); } public eraserMode () { this._selection = new Uint8Array((this._width / 8) * this._height); this._editorMode = Mode.ERASER; + this._redraw(); } public selectionMode () { this._editorMode = Mode.SELECTION; + this._redraw(); }