otg msd: notify about free space while uploading

This commit is contained in:
Devaev Maxim
2019-11-08 03:53:00 +03:00
parent 13dcbc0c62
commit fa40676136
3 changed files with 88 additions and 19 deletions

View File

@@ -195,8 +195,10 @@ export function Msd() {
$("msd-emulate-cdrom-checkbox").checked = (__state.online && __state.features.cdrom && __state.drive.cdrom);
$("msd-new-image").style.display = (__image_file ? "block" : "none");
$("msd-uploading-progress").setAttribute("data-label", "Waiting for upload ...");
$("msd-uploading-progress-value").style.width = "0%";
if (!__upload_http) {
$("msd-uploading-progress").setAttribute("data-label", "Waiting for upload ...");
$("msd-uploading-progress-value").style.width = "0%";
}
$("msd-new-image-name").innerHTML = (__image_file ? __image_file.name : "");
$("msd-new-image-size").innerHTML = (__image_file ? __formatSize(__image_file.size) : "");