mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-05-22 04:28:05 +08:00
Rename SkeinPanel::on_close() to make it more generice
This commit is contained in:
parent
4f179a5197
commit
df658eb636
@ -127,7 +127,7 @@ sub about {
|
||||
|
||||
sub on_close {
|
||||
my ($frame, $event) = @_;
|
||||
$event->CanVeto ? $event->Skip($frame->{skeinpanel}->on_close) : $event->Skip(1);
|
||||
$event->CanVeto ? $event->Skip($frame->{skeinpanel}->check_unsaved_changes) : $event->Skip(1);
|
||||
}
|
||||
|
||||
sub catch_error {
|
||||
|
@ -232,7 +232,7 @@ sub config_wizard {
|
||||
}
|
||||
}
|
||||
|
||||
sub on_close {
|
||||
sub check_unsaved_changes {
|
||||
my $self = shift;
|
||||
|
||||
my @dirty;
|
||||
@ -242,7 +242,7 @@ sub on_close {
|
||||
|
||||
if (@dirty) {
|
||||
my $titles = join ', ', @dirty;
|
||||
my $confirm = Wx::MessageDialog->new($self, "You have unsaved changes ($titles). Exit anyway?",
|
||||
my $confirm = Wx::MessageDialog->new($self, "You have unsaved changes ($titles). Discard changes and continue anyway?",
|
||||
'Unsaved Presets', wxICON_QUESTION | wxOK | wxCANCEL);
|
||||
return ($confirm->ShowModal == wxID_OK);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user