From b6603c6c2e319ca0b29f683d8b28ce1a45bacb3d Mon Sep 17 00:00:00 2001 From: mattk70 Date: Wed, 30 Oct 2024 21:05:51 +0000 Subject: [PATCH] Fixed sample rate problem in UI Fixed position of refernce call zoom buttons --- css/style.css | 4 +++- js/ui.js | 5 ++--- js/worker.js | 9 +++------ 3 files changed, 8 insertions(+), 10 deletions(-) diff --git a/css/style.css b/css/style.css index f6f8746..e7d4e93 100644 --- a/css/style.css +++ b/css/style.css @@ -144,7 +144,9 @@ div#contentWrapper.loaded { position: absolute; font-size: calc(32px * var(--font-size-scale));; } - +.zoom-xc { + font-size: calc(32px * var(--font-size-scale));; +} .species-selector { position: relative; } diff --git a/js/ui.js b/js/ui.js index 19cdb66..ffe3c6c 100644 --- a/js/ui.js +++ b/js/ui.js @@ -3014,7 +3014,6 @@ function centreSpec(){ function onModelReady(args) { modelReady = true; - sampleRate = args.sampleRate; if (fileLoaded) { enableMenuItem(['analyse']) if (STATE.openFiles.length > 1) enableMenuItem(['analyseAll', 'reanalyseAll']) @@ -5615,10 +5614,10 @@ function renderComparisons(lists, cname){
diff --git a/js/worker.js b/js/worker.js index e6d1a89..42cb6a7 100644 --- a/js/worker.js +++ b/js/worker.js @@ -20,7 +20,7 @@ if (process.platform === 'win32') { ntsuspend = require('ntsuspend'); isWin32 = true; } -const DEBUG = false; +const DEBUG = true; // Function to join Buffers and not use Buffer.concat() which leads to detached ArrayBuffers function joinBuffers(buffer1, buffer2) { @@ -1311,7 +1311,6 @@ function checkBacklog(ffmpegCommand = null) { const interval = setInterval(() => { const backlog = AUDIO_BACKLOG; - if (aborted) { clearInterval(interval); resolve(false); @@ -2197,12 +2196,10 @@ async function parseMessage(e) { SEEN_MODEL_READY = true; sampleRate = response["sampleRate"]; const backend = response["backend"]; - console.log(backend); + DEBUG && console.log(backend); UI.postMessage({ event: "model-ready", - message: "ready", - backend: backend, - sampleRate: sampleRate + message: "Give It To Me Baby. Uh-Huh Uh-Huh" }); } break;