diff --git a/languages/en_CA.json b/languages/en_CA.json index bd637e50..3d50d259 100644 --- a/languages/en_CA.json +++ b/languages/en_CA.json @@ -498,10 +498,10 @@ "Compress Videos": "Compress Videos", "FixVideoMsg": "Do you want to fix this video? This will create a new file and overwrite the old one. You cannot undo this action.", "DeleteVideoMsg": "Do you want to delete this video? You cannot recover it.", - "CompressVideoMsg": "Do you want to compress this video? The original will be moved to your FileBin.", + "CompressVideoMsg": "Do you want to compress this video? The original will be moved to your FileBin. Videos that are already completed compressing will be skipped if already queued.", "DeleteThisMsg": "Do you want to delete this? You cannot recover it.", "DeleteTheseMsg": "Do you want to delete these? You cannot recover them.", - "CompressTheseMsg": "Do you want to compress these? The originals will be moved to your FileBin. Videos that are already WebM will be skipped.", + "CompressTheseMsg": "Do you want to compress these? The originals will be moved to your FileBin. Videos that are already WebM will be skipped. Videos that are already completed compressing will be skipped if ordered to compress again.", "dropBoxSuccess": "Success! Files saved to your Dropbox.", "API Key Deleted": "API Key Deleted", "APIKeyDeletedText": "Key has been deleted. It will no longer work.", diff --git a/web/assets/js/bs5.videosTable.js b/web/assets/js/bs5.videosTable.js index 4583f12b..25005a1b 100644 --- a/web/assets/js/bs5.videosTable.js +++ b/web/assets/js/bs5.videosTable.js @@ -212,6 +212,9 @@ $(document).ready(function(e){
${data.percent}%
+ @@ -344,24 +347,28 @@ $(document).ready(function(e){ break; case'video_compress_completed': if(data.success){ - var saveBuiltVideo = dashboardOptions().switches.saveCompressedVideo - if(data.timelapseVideo && saveBuiltVideo === 1){ - downloadCompressedVideo(data) - } var progressItem = sideLinkListBox.find(`[data-mid="${data.mid}"][data-ke="${data.mid}"][data-name="${data.name}"]`) - progressItem.find('.row-status').text(`${lang.Done}!`) - progressItem.find('.dot').removeClass('dot-orange').addClass('dot-green') - progressItem.find('.download-button').show() + var saveBuiltVideo = dashboardOptions().switches.saveCompressedVideo + if(saveBuiltVideo === 1){ + downloadCompressedVideo(data) + progressItem.remove() + console.log(`Downloaded!`,data) + }else{ + progressItem.find('.row-status').text(`${lang.Done}!`) + progressItem.find('.dot').removeClass('dot-orange').addClass('dot-green') + progressItem.find('.download-button').show() + progressItem.find('.progress-bar').css('width',`100%`).text(`100%`) + } } break; case'video_compress_percent': var progressItem = sideLinkListBox.find(`[data-mid="${data.mid}"][data-ke="${data.mid}"][data-name="${data.name}"]`) + data.percent = data.percent > 100 ? 100 : data.percent if(progressItem.length === 0){ drawCompressedVideoProgressBar(data) }else{ progressItem = sideLinkListBox.find(`[data-mid="${data.mid}"][data-ke="${data.mid}"][data-name="${data.name}"]`) progressItem.find('.progress-bar').css('width',`${data.percent}%`).text(`${data.percent}%`) - progressItem.find('.percent').text(data.percent) } console.log(data) break;