.
This commit is contained in:
@@ -11,7 +11,6 @@
|
|||||||
|
|
||||||
// set to hold the files that are still being processed
|
// set to hold the files that are still being processed
|
||||||
let active_file_inputs = new Set();
|
let active_file_inputs = new Set();
|
||||||
let drops_processing = false;
|
|
||||||
|
|
||||||
async function listAllFilesAndDirs(dirHandle, files_only) {
|
async function listAllFilesAndDirs(dirHandle, files_only) {
|
||||||
const files = [];
|
const files = [];
|
||||||
@@ -231,7 +230,6 @@
|
|||||||
|
|
||||||
// Loop through each dropped file and try to assign to an
|
// Loop through each dropped file and try to assign to an
|
||||||
// input element
|
// input element
|
||||||
drops_processing = true;
|
|
||||||
[...evt.dataTransfer.files].forEach((f) => {
|
[...evt.dataTransfer.files].forEach((f) => {
|
||||||
feedback = false;
|
feedback = false;
|
||||||
if (evt.target.id == "feedback-drop-target") {
|
if (evt.target.id == "feedback-drop-target") {
|
||||||
@@ -239,7 +237,6 @@
|
|||||||
}
|
}
|
||||||
addFile(f, feedback)
|
addFile(f, feedback)
|
||||||
})
|
})
|
||||||
drops_processing = false;
|
|
||||||
|
|
||||||
evt.preventDefault();
|
evt.preventDefault();
|
||||||
evt.stopPropagation();
|
evt.stopPropagation();
|
||||||
@@ -489,7 +486,7 @@ setTimeout(function (){
|
|||||||
active_file_inputs.delete(el)
|
active_file_inputs.delete(el)
|
||||||
console.log("active", active_file_inputs)
|
console.log("active", active_file_inputs)
|
||||||
// Only load once all queued files have been processed
|
// Only load once all queued files have been processed
|
||||||
if (active_file_inputs.size < 1 && !drops_processing) {
|
if (active_file_inputs.size < 1) {
|
||||||
loadViewer();
|
loadViewer();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user