From 82cfc7c3d62f0da8462ac0a7f4bd92fa4d7c25e7 Mon Sep 17 00:00:00 2001 From: Henrik Brix Andersen Date: Tue, 17 Jul 2012 23:16:58 +0200 Subject: [PATCH] Check for unsaved presets before interactively loading an existing config file. --- lib/Slic3r/GUI/SkeinPanel.pm | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/Slic3r/GUI/SkeinPanel.pm b/lib/Slic3r/GUI/SkeinPanel.pm index aaf7c5cd1..ed46d7269 100644 --- a/lib/Slic3r/GUI/SkeinPanel.pm +++ b/lib/Slic3r/GUI/SkeinPanel.pm @@ -184,6 +184,7 @@ sub load_config { my ($file) = @_; if (!$file) { + return unless $self->check_unsaved_changes; my $dir = $last_config ? dirname($last_config) : $last_config_dir || $last_skein_dir || ""; my $dlg = Wx::FileDialog->new($self, 'Select configuration to load:', $dir, "config.ini", $ini_wildcard, wxFD_OPEN | wxFD_FILE_MUST_EXIST);