From 22ed872748066a563fd17c7310b031abcabcf2a8 Mon Sep 17 00:00:00 2001 From: Davor Hrg Date: Tue, 12 Mar 2024 18:01:35 +0100 Subject: [PATCH] update engine test to new worker --- apps/engine-test/main.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/engine-test/main.js b/apps/engine-test/main.js index 8aacdb6..0edc827 100644 --- a/apps/engine-test/main.js +++ b/apps/engine-test/main.js @@ -128,7 +128,7 @@ document.body.ondrop = async ev => { const { alias, script } = await fileDropped(sw, files) projectName = sw.projectName if (alias.length) { - sendNotify('init', [{ alias }]) + workerApi.init({ alias }) } runScript({ url: sw.fileToRun, base: sw.base }) } catch (error) { @@ -246,7 +246,7 @@ async function initFs() { sw = await registerServiceWorker('bundle.fs-serviceworker.js?prefix=/swfs/') sw.defProjectName = 'jscad' sw.onfileschange = files => { - sendNotify('clearFileCache', [{ files }]) + workerApi.clearFileCache({ files }) if (sw.fileToRun) runScript({ url: sw.fileToRun, base: sw.base }) } }