Show that DeadAir is still working on an episode (#176)
A new download in a show with DeadAir on plays at full length until its copy is made, and nothing said so. Each file now carries deadair_pending while DeadAir is on for its show and the copy is still to come (not for one heard through, which it passes over), and the episode's line and details say "Cutting dead air…". The maker sends a deadair_done event when it finishes a file, and the page takes the list again, so the line becomes how much shorter the episode is without a reload. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -35,6 +35,13 @@ function connect(){
|
||||
if(bar){ bar.classList.remove('live'); toast('Downloaded '+ev.path.split('/').pop()); }
|
||||
refreshEntries();
|
||||
}
|
||||
// A copy finished: the episode's "Cutting dead air…" becomes how much shorter it is.
|
||||
else if(ev.ev==='deadair_done'){
|
||||
if(!mine(ev.feed)) return;
|
||||
if(ev.saved_s>0&&document.querySelector('.dapend')) toast(`DeadAir is done: ${shorter(ev.saved_s)}`);
|
||||
refreshEntries();
|
||||
if(S.sel) loadEntries().then(()=>{ const e=cur(); if(e) showDetail(e); }).catch(()=>{});
|
||||
}
|
||||
else if(ev.ev==='download_error'){
|
||||
const bar=document.querySelector(`.dlbar[data-bar="${ev.enclosure}"]`);
|
||||
if(bar) bar.classList.remove('live');
|
||||
|
||||
Reference in New Issue
Block a user