diff options
author | Michael Straßburger <codepoet@cpan.org> | 2017-04-30 00:09:28 +0200 |
---|---|---|
committer | Michael Straßburger <codepoet@cpan.org> | 2017-04-30 00:09:28 +0200 |
commit | 8edd70c5bbce2f6fbf63df00feb0132702db0813 (patch) | |
tree | 0c61ab176b98c3c220e8863c9676f3dfafab5a18 | |
parent | fcfb090a52995a483acc942cdd82b2d0682ed12f (diff) |
:art: moving onDraw to onUpdate
-rw-r--r-- | src/Mapscii.coffee | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Mapscii.coffee b/src/Mapscii.coffee index ecd35b1..5a6d3b2 100644 --- a/src/Mapscii.coffee +++ b/src/Mapscii.coffee @@ -184,7 +184,6 @@ module.exports = class Mapscii #@notify JSON.stringify key _draw: -> - config.onDraw() if config.onDraw @renderer .draw @center, @zoom .then (frame) => @@ -209,6 +208,7 @@ module.exports = class Mapscii "mouse: #{utils.digits @mousePosition.lat, 3}, #{utils.digits @mousePosition.lon, 3} " notify: (text) -> + config.onUpdate() if config.onUpdate @_write "\r\x1B[K"+text unless config.headless _write: (output) -> |