From f9b6caaecb8cbf2be940de68fcbba4a1f5c7f0f6 Mon Sep 17 00:00:00 2001 From: Alessandro Ranellucci Date: Sun, 28 Oct 2012 12:22:30 +0100 Subject: [PATCH] Bugfix, last commit was incomplete --- lib/Slic3r/Layer/Region.pm | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/lib/Slic3r/Layer/Region.pm b/lib/Slic3r/Layer/Region.pm index dd16c17d0..f765b6e03 100644 --- a/lib/Slic3r/Layer/Region.pm +++ b/lib/Slic3r/Layer/Region.pm @@ -48,8 +48,19 @@ has 'perimeters' => (is => 'rw', default => sub { [] }); # ordered collection of extrusion paths to fill surfaces has 'fills' => (is => 'rw', default => sub { [] }); +sub BUILD { + my $self = shift; + $self->_update_flows; +} + sub _trigger_layer { my $self = shift; + $self->_update_flows; +} + +sub _update_flows { + my $self = shift; + return if !$self->region; $self->perimeter_flow($self->id == 0 ? $self->region->first_layer_flows->{perimeter}