mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-16 11:17:51 -06:00
NEW: add track events for debugging network
Change-Id: I671f91b4af00277236ca71014f8d667109756d00 Signed-off-by: Stone Li <stone.li@bambulab.com>
This commit is contained in:
parent
bd75af4a43
commit
6827b41eb3
13 changed files with 187 additions and 12 deletions
|
@ -481,14 +481,12 @@ void PrinterFileSystem::DownloadNextFile()
|
|||
download->index = FindFile(download->index, download->name);
|
||||
if (download->index != size_t(-1)) {
|
||||
int progress = data.size * 100 / data.total;
|
||||
if (result > CONTINUE)
|
||||
progress = -2;
|
||||
auto & file = m_file_list[download->index];
|
||||
if (result == ERROR_CANCEL)
|
||||
file.flags &= ~FF_DOWNLOAD;
|
||||
else if (file.progress != progress) {
|
||||
file.progress = progress;
|
||||
SendChangedEvent(EVT_DOWNLOAD, download->index, file.path, data.size);
|
||||
SendChangedEvent(EVT_DOWNLOAD, download->index, file.path, result);
|
||||
}
|
||||
}
|
||||
if (result != CONTINUE) DownloadNextFile();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue