mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-13 18:18:57 +08:00
Rename non-printer user preset: Fixed wrong condition to show "Rename" button
(SPE-2472)
This commit is contained in:
parent
150db9912c
commit
76313f5148
@ -3804,10 +3804,11 @@ void Tab::update_btns_enabling()
|
||||
// we can delete any preset from the physical printer
|
||||
// and any user preset
|
||||
const Preset& preset = m_presets->get_edited_preset();
|
||||
m_btn_delete_preset->Show((m_type == Preset::TYPE_PRINTER && m_preset_bundle->physical_printers.has_selection())
|
||||
|| (!preset.is_default && !preset.is_system));
|
||||
m_btn_rename_preset->Show(!preset.is_default && !preset.is_system && !preset.is_external &&
|
||||
!wxGetApp().preset_bundle->physical_printers.has_selection());
|
||||
const bool is_printer_and_selected_physical = m_type == Preset::TYPE_PRINTER && m_preset_bundle->physical_printers.has_selection();
|
||||
|
||||
m_btn_delete_preset->Show(is_printer_and_selected_physical || (!preset.is_default && !preset.is_system));
|
||||
|
||||
m_btn_rename_preset->Show(!is_printer_and_selected_physical && !preset.is_default && !preset.is_system && !preset.is_external);
|
||||
|
||||
if (m_btn_edit_ph_printer)
|
||||
m_btn_edit_ph_printer->SetToolTip( m_preset_bundle->physical_printers.has_selection() ?
|
||||
|
Loading…
x
Reference in New Issue
Block a user