From a0f12faee513866c22c04b867ef716df48904223 Mon Sep 17 00:00:00 2001 From: njanssen Date: Fri, 25 Sep 2020 10:46:16 +0200 Subject: Allow Midi.play and Midi.stop to update `Midi.isPaused` when running in Puppeteering mode (thanks @unthingable!) --- desktop/sources/scripts/clock.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'desktop/sources/scripts/clock.js') diff --git a/desktop/sources/scripts/clock.js b/desktop/sources/scripts/clock.js index 1739dd0..a170e2c 100644 --- a/desktop/sources/scripts/clock.js +++ b/desktop/sources/scripts/clock.js @@ -59,8 +59,8 @@ function Clock (client) { this.play = function (msg = false) { console.log('Clock', 'Play', msg) if (this.isPaused === false) { return } - if (this.isPuppet === true) { console.warn('Clock', 'External Midi control'); return } this.isPaused = false + if (this.isPuppet === true) { console.warn('Clock', 'External Midi control'); return } if (msg === true) { client.io.midi.sendClockStart() } this.setSpeed(this.speed.target, this.speed.target, true) } @@ -68,8 +68,8 @@ function Clock (client) { this.stop = function (msg = false) { console.log('Clock', 'Stop') if (this.isPaused === true) { return } - if (this.isPuppet === true) { console.warn('Clock', 'External Midi control'); return } this.isPaused = true + if (this.isPuppet === true) { console.warn('Clock', 'External Midi control'); return } if (msg === true || client.io.midi.isClock) { client.io.midi.sendClockStop() } client.io.midi.allNotesOff() this.clearTimer() -- cgit v1.2.3