mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-23 06:33:57 -06:00
Handle non existing STL files gracefully
This commit is contained in:
parent
9b2445f0f5
commit
d1bb69434e
2 changed files with 8 additions and 3 deletions
|
@ -382,10 +382,12 @@ sub load_file {
|
|||
my $model = eval { Slic3r::Model->read_from_file($input_file) };
|
||||
Slic3r::GUI::show_error($self, $@) if $@;
|
||||
|
||||
$self->load_model_objects(@{$model->objects});
|
||||
if (defined $model) {
|
||||
$self->load_model_objects(@{$model->objects});
|
||||
$self->statusbar->SetStatusText("Loaded " . basename($input_file));
|
||||
}
|
||||
|
||||
$process_dialog->Destroy;
|
||||
$self->statusbar->SetStatusText("Loaded " . basename($input_file));
|
||||
}
|
||||
|
||||
sub load_model_objects {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue