From e5ce29a4e9d7bc3f11803b8e14bbcb6aa54eda38 Mon Sep 17 00:00:00 2001 From: themancalledjakob Date: Sat, 16 Mar 2024 14:46:05 +0100 Subject: [PATCH] remove canvasCombos from all layers --- bin/em/variabletime/web/js/audio.js | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/bin/em/variabletime/web/js/audio.js b/bin/em/variabletime/web/js/audio.js index dddb655..5af4429 100644 --- a/bin/em/variabletime/web/js/audio.js +++ b/bin/em/variabletime/web/js/audio.js @@ -634,17 +634,17 @@ const Audio = function(tp, record) { button.classList.remove('active'); }); } else { + if (config.audio.colorSeparateRGBA && propTitle === 'color') { + delete canvasCombos['color.r']; + delete canvasCombos['color.g']; + delete canvasCombos['color.b']; + delete canvasCombos['color.a']; + } else { + delete canvasCombos[propTitle]; + } // only selected layers have options // otherwise the ui is not there if (layer.isSelected()) { - if (config.audio.colorSeparateRGBA && propTitle === 'color') { - delete canvasCombos['color.r']; - delete canvasCombos['color.g']; - delete canvasCombos['color.b']; - delete canvasCombos['color.a']; - } else { - delete canvasCombos[propTitle]; - } const audioOptions = panel.querySelectorAll(toCssClass(`audioOptions${propTitle}`,'.')); if (audioOptions.length > 0) { audioOptions.forEach((e) => { e.remove(); });