mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-14 06:55:53 +08:00
Fixed a Crash on switch printer technology, when "Materials" tab is shown.
+ Fixed Plater selection, when no"Printer" tab is selected and some printer with other technology is installed from Wizard (SPE-2459)
This commit is contained in:
parent
016103dd95
commit
6782922d8b
@ -3308,6 +3308,13 @@ bool GUI_App::run_wizard(ConfigWizard::RunReason reason, ConfigWizard::StartPage
|
||||
if (res) {
|
||||
load_current_presets();
|
||||
|
||||
for (Tab* tab : tabs_list) {
|
||||
if (tab->type() == Preset::TYPE_PRINTER) {
|
||||
if (!tab->IsShown())
|
||||
mainframe->select_tab(size_t(0));
|
||||
break;
|
||||
}
|
||||
}
|
||||
// #ysFIXME - delete after testing: This part of code looks redundant. All checks are inside ConfigWizard::priv::apply_config()
|
||||
if (preset_bundle->printers.get_edited_preset().printer_technology() == ptSLA)
|
||||
may_switch_to_SLA_preset(_L("Configuration is editing from ConfigWizard"));
|
||||
|
@ -5548,9 +5548,8 @@ void TabSLAMaterial::update()
|
||||
void TabSLAMaterial::update_description_lines()
|
||||
{
|
||||
if (m_active_page && m_active_page->title() == "Material" && m_z_correction_to_mm_description) {
|
||||
auto cfg = m_preset_bundle->full_config();
|
||||
double lh = cfg.opt_float("layer_height");
|
||||
int zlayers = cfg.opt_int("zcorrection_layers");
|
||||
double lh = m_preset_bundle->sla_prints.get_edited_preset().config.opt_float("layer_height");
|
||||
int zlayers = m_config->opt_int("zcorrection_layers");
|
||||
m_z_correction_to_mm_description->SetText(GUI::format_wxstr(_L("The current Z-axis height correction is: %1% mm"), zlayers * lh));
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user