Stop background process when removing objects from the plater

This commit is contained in:
Alessandro Ranellucci 2014-06-14 20:26:53 +02:00
parent 301771e275
commit 51cf78534c

View file

@ -475,6 +475,8 @@ sub remove {
my $self = shift;
my ($obj_idx) = @_;
$self->stop_background_process;
# if no object index is supplied, remove the selected one
if (!defined $obj_idx) {
($obj_idx, undef) = $self->selected_object;
@ -489,11 +491,15 @@ sub remove {
$self->select_object(undef);
$self->update;
$self->{canvas}->Refresh;
$self->schedule_background_process;
}
sub reset {
my $self = shift;
$self->stop_background_process;
@{$self->{objects}} = ();
$self->{model}->clear_objects;
$self->{print}->clear_objects;