mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-08 23:46:24 -06:00
FIX: button handle key event
Change-Id: If3ecd2356e516105c2054c9b85a122f3ccc72d91
This commit is contained in:
parent
6c4b1f79da
commit
a74fb14613
6 changed files with 59 additions and 9 deletions
|
@ -955,7 +955,7 @@ void UnsavedChangesDialog::build(Preset::Type type, PresetCollection *dependent_
|
|||
(*btn)->SetMinSize(UNSAVE_CHANGE_DIALOG_BUTTON_SIZE);
|
||||
(*btn)->SetCornerRadius(12);
|
||||
|
||||
(*btn)->Bind(wxEVT_LEFT_DOWN, [this, close_act, dependent_presets](wxEvent &) {
|
||||
(*btn)->Bind(wxEVT_BUTTON, [this, close_act, dependent_presets](wxEvent &) {
|
||||
bool save_names_and_types = close_act == Action::Save || (close_act == Action::Transfer && ActionButtons::KEEP & m_buttons);
|
||||
if (save_names_and_types && !save(dependent_presets, close_act == Action::Save)) return;
|
||||
close(close_act);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue