mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-11 11:28:58 +08:00
Process events while extracting the downloaded backup
To prevent the UI from being frozen. This way, the user knows that something is happening in the background and Cura didn't just stop working. CURA-8313
This commit is contained in:
parent
4f5e055cd8
commit
bcd44b8b6f
@ -194,7 +194,10 @@ class Backup:
|
||||
Resources.factoryReset()
|
||||
Logger.log("d", "Extracting backup to location: %s", target_path)
|
||||
try:
|
||||
archive.extractall(target_path)
|
||||
name_list = archive.namelist()
|
||||
for archive_filename in name_list:
|
||||
archive.extract(archive_filename, target_path)
|
||||
CuraApplication.getInstance().processEvents()
|
||||
except (PermissionError, EnvironmentError):
|
||||
Logger.logException("e", "Unable to extract the backup due to permission or file system errors.")
|
||||
return False
|
||||
|
Loading…
x
Reference in New Issue
Block a user