From 62ee79f0c9b6303e3b0aef6e8bd9693985f68574 Mon Sep 17 00:00:00 2001 From: Alessandro Ranellucci Date: Mon, 26 Dec 2011 19:45:01 +0100 Subject: [PATCH] Remember last config file path when loaded from CLI too --- lib/Slic3r/GUI/SkeinPanel.pm | 2 +- slic3r.pl | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/Slic3r/GUI/SkeinPanel.pm b/lib/Slic3r/GUI/SkeinPanel.pm index c9906a01d..d5fa0ab89 100644 --- a/lib/Slic3r/GUI/SkeinPanel.pm +++ b/lib/Slic3r/GUI/SkeinPanel.pm @@ -10,7 +10,7 @@ use Wx::Event qw(EVT_BUTTON); use base 'Wx::Panel'; my $last_dir; -my $last_config; +our $last_config; sub new { my $class = shift; diff --git a/slic3r.pl b/slic3r.pl index e81b9592b..0fb53578c 100755 --- a/slic3r.pl +++ b/slic3r.pl @@ -59,6 +59,8 @@ Slic3r::Config->save($opt{save}) if $opt{save}; # start GUI if (!@ARGV && !$opt{save} && eval "require Slic3r::GUI; 1") { + no warnings 'once'; + $Slic3r::GUI::SkeinPanel::last_config = $opt{load}; Slic3r::GUI->new->MainLoop; exit; }