diff options
| author | skal <pascal.massimino@gmail.com> | 2026-01-28 12:12:03 +0100 |
|---|---|---|
| committer | skal <pascal.massimino@gmail.com> | 2026-01-28 12:12:03 +0100 |
| commit | 2021ebe9013a583363e0619d70b3e9b82a929fbd (patch) | |
| tree | de2ebbe287c02fd188326c3428ccdcf3e36b7d30 /tools | |
| parent | 1742f917ef417b9c5edb549a5883a96a6018d3d7 (diff) | |
fix(editor): Resolve duplicate variable declarations in script.js
Consolidated all button element declarations into a single block to prevent 'Identifier has already been declared' errors.
Diffstat (limited to 'tools')
| -rw-r--r-- | tools/editor/script.js | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/tools/editor/script.js b/tools/editor/script.js index c764803..46cbe1d 100644 --- a/tools/editor/script.js +++ b/tools/editor/script.js @@ -444,27 +444,6 @@ lineToolButton.addEventListener('click', () => { activeTool = 'line'; console.lo ellipseToolButton.addEventListener('click', () => { activeTool = 'ellipse'; console.log('Ellipse tool selected'); }); noiseToolButton.addEventListener('click', () => { activeTool = 'noise'; console.log('Noise tool selected'); }); -undoButton.addEventListener('click', handleUndo); -redoButton.addEventListener('click', handleRedo); - -listenOriginalButton.addEventListener('click', () => { - if (originalSpecData) { - playSpectrogramData(originalSpecData); - } else { - alert("No original SPEC data loaded."); - } -}); - -listenGeneratedButton.addEventListener('click', () => { - if (currentSpecData) { - // Ensure currentSpecData reflects all shapes before playing - redrawCanvas(); // This updates currentSpecData based on shapes - playSpectrogramData(currentSpecData); - } else { - alert("No generated SPEC data to play."); - } -}); - // --- Undo/Redo Logic --- function addAction(action) { undoStack.push(action); |
