Enforce prompt when overwriting G-code files. #398
This commit is contained in:
parent
949055d86c
commit
5eae22f8b0
2 changed files with 2 additions and 2 deletions
|
@ -561,7 +561,7 @@ sub export_stl {
|
|||
$output_file = $print->expanded_output_filepath($output_file);
|
||||
$output_file =~ s/\.gcode$/.stl/i;
|
||||
my $dlg = Wx::FileDialog->new($self, 'Save STL file as:', dirname($output_file),
|
||||
basename($output_file), $Slic3r::GUI::SkeinPanel::model_wildcard, wxFD_SAVE);
|
||||
basename($output_file), $Slic3r::GUI::SkeinPanel::model_wildcard, wxFD_SAVE | &Wx::wxFD_OVERWRITE_PROMPT);
|
||||
if ($dlg->ShowModal != wxID_OK) {
|
||||
$dlg->Destroy;
|
||||
return;
|
||||
|
|
|
@ -294,7 +294,7 @@ sub save_config {
|
|||
my $dir = $last_config ? dirname($last_config) : $last_config_dir || $last_skein_dir || "";
|
||||
my $filename = $last_config ? basename($last_config) : "config.ini";
|
||||
my $dlg = Wx::FileDialog->new($self, 'Save configuration as:', $dir, $filename,
|
||||
$ini_wildcard, wxFD_SAVE);
|
||||
$ini_wildcard, wxFD_SAVE | &Wx::wxFD_OVERWRITE_PROMPT);
|
||||
if ($dlg->ShowModal == wxID_OK) {
|
||||
my $file = $dlg->GetPath;
|
||||
$last_config_dir = dirname($file);
|
||||
|
|
Loading…
Reference in a new issue