MSW specific: Fixed strange layout after first switch between printer technology

This commit is contained in:
YuSanka 2021-07-27 10:54:31 +02:00
parent 2c6cd95b39
commit 3449550a7c

View File

@ -3059,6 +3059,7 @@ void Tab::load_current_preset()
if (!wxGetApp().tabs_as_menu()) { if (!wxGetApp().tabs_as_menu()) {
std::string bmp_name = tab->type() == Slic3r::Preset::TYPE_FILAMENT ? "spool" : std::string bmp_name = tab->type() == Slic3r::Preset::TYPE_FILAMENT ? "spool" :
tab->type() == Slic3r::Preset::TYPE_SLA_MATERIAL ? "resin" : "cog"; tab->type() == Slic3r::Preset::TYPE_SLA_MATERIAL ? "resin" : "cog";
tab->Hide(); // #ys_WORKAROUND : Hide tab before inserting to avoid unwanted rendering of the tab
dynamic_cast<Notebook*>(wxGetApp().tab_panel())->InsertPage(wxGetApp().tab_panel()->FindPage(this), tab, tab->title(), bmp_name); dynamic_cast<Notebook*>(wxGetApp().tab_panel())->InsertPage(wxGetApp().tab_panel()->FindPage(this), tab, tab->title(), bmp_name);
} }
else else