a skip during the hold drops the waiting track instead of playing it
shots / shots (push) Successful in 2m15s
shots / shots (push) Successful in 2m15s
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01K6897PWcUEwHiqZMcVnNF6
This commit is contained in:
1 parent
bc4f1c8499
commit
d062e2a067
1 file changed
+1
@@ -1180,6 +1180,7 @@ state.audio.addEventListener("ended", () => {
|
||||
// the crackle finishing its loop with a track waiting: hand over right here, synchronously
|
||||
if (state.holding && state.pendingJob) {
|
||||
const job = state.pendingJob; state.pendingJob = null; state.holding = false;
|
||||
if (state.current !== job) { const go = state.onHoldEnd; state.onHoldEnd = null; if (go) go(); state.playing = false; setPlayIcon(); swapNow(); advance(); return; }
|
||||
try { state.audio.loop = !!state.loop; state.audio.src = job.url || (job.url = URL.createObjectURL(job.blob)); const p = state.audio.play(); if (p && p.catch) p.catch(() => {}); job.preplayed = true; } catch {}
|
||||
const go = state.onHoldEnd; state.onHoldEnd = null; if (go) go();
|
||||
return;
|
||||
|
||||
Reference in new issue
Block a user