Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/sn4k3/UVtools.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTiago Conceição <Tiago_caza@hotmail.com>2020-09-14 23:55:04 +0300
committerTiago Conceição <Tiago_caza@hotmail.com>2020-09-14 23:55:04 +0300
commit8bec024315d74b0b426c4918137bda0eda31bcc6 (patch)
treef61fc09bb4d365832388a124f7520cc4d31331fb /UVtools.GUI
parent4cf6be8c97647e07670c250e548c26f7e05f85c9 (diff)
Fix ctb and pws
* (Fix) ctb and pws: Renders a bad file after save, this was introduced with cancelled saves feature * (Fix) When cancel a file convertion, it now deletes the target file
Diffstat (limited to 'UVtools.GUI')
-rw-r--r--UVtools.GUI/FrmMain.cs7
1 files changed, 5 insertions, 2 deletions
diff --git a/UVtools.GUI/FrmMain.cs b/UVtools.GUI/FrmMain.cs
index bb76ccf..e989c36 100644
--- a/UVtools.GUI/FrmMain.cs
+++ b/UVtools.GUI/FrmMain.cs
@@ -1424,7 +1424,10 @@ namespace UVtools.GUI
}
catch (OperationCanceledException)
{
-
+ if (File.Exists(dialog.FileName))
+ {
+ File.Delete(dialog.FileName);
+ }
}
catch (Exception ex)
{
@@ -2013,7 +2016,7 @@ namespace UVtools.GUI
}
var oldFile = SlicerFile.FileFullPath;
- var tempFile = filepath + ".tmp";
+ var tempFile = filepath + FileFormat.TemporaryFileAppend;
DisableGUI();
FrmLoading.SetDescription($"Saving {Path.GetFileName(filepath)}");