mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-12 21:59:08 +08:00
Scoping error caused the Unsaved Changes dialog not to be shown when closing the main window
This commit is contained in:
parent
c1e44eb591
commit
959eb60ad0
@ -673,7 +673,11 @@ sub config {
|
||||
sub check_unsaved_changes {
|
||||
my $self = shift;
|
||||
|
||||
my @dirty = map $_->title, grep $_->is_dirty, values %{$self->{options_tabs}};
|
||||
my @dirty = ();
|
||||
foreach my $tab (values %{$self->{options_tabs}}) {
|
||||
push @dirty, $tab->title if $tab->is_dirty;
|
||||
}
|
||||
|
||||
if (@dirty) {
|
||||
my $titles = join ', ', @dirty;
|
||||
my $confirm = Wx::MessageDialog->new($self, "You have unsaved changes ($titles). Discard changes and continue anyway?",
|
||||
|
Loading…
x
Reference in New Issue
Block a user