mirror of
https://gitlab.rlp.net/proj-wise2526-video2document/video2document.git
synced 2026-06-15 18:01:52 +02:00
Merge branch 'feature/ui-test' into 'develop'
Implemented the function for the download button. See merge request proj-wise2526-video2document/video2document!49
This commit is contained in:
@@ -147,12 +147,7 @@
|
||||
</div>
|
||||
|
||||
<div class="step" id="step6" style="display:none;">
|
||||
<button class="download-btn" id="downloadButton" onclick="" disabled>Download</button>
|
||||
|
||||
<div class="progressbar" id="progressbar">
|
||||
<div class="progress_fill"></div>
|
||||
<span class="progress_text">0%</span>
|
||||
</div>
|
||||
<button class="download-btn" id="downloadButton" disabled>Download</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -26,6 +26,11 @@ try {
|
||||
submitSpeaker: (speaker_names) => {ipcRenderer.send("speaker_submit", speaker_names)}
|
||||
})
|
||||
|
||||
contextBridge.exposeInMainWorld("download", {
|
||||
file_download: () => {ipcRenderer.send("file_download")}
|
||||
})
|
||||
|
||||
|
||||
ipcRenderer.on("error", (event, err) => {alert(err)})
|
||||
} catch (error) {
|
||||
console.log("Error in preload.js");
|
||||
|
||||
@@ -105,7 +105,6 @@ function changeLanguage(language) {
|
||||
function handleFiles(files) {
|
||||
try {
|
||||
if (files.length > 0) {
|
||||
document.getElementById("progressbar").style.visibility = "visible";
|
||||
const file = files[0];
|
||||
if (file.type.startsWith('video/')) {
|
||||
const filePath = window.explorer.onFileDrop(files[0])
|
||||
@@ -330,3 +329,10 @@ function sendSpeakerPackages(){
|
||||
}
|
||||
}
|
||||
|
||||
function fileDownload(){
|
||||
try {
|
||||
window.file_download.fileDownload();
|
||||
} catch (error) {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user