From c4de398d309fb0ca44b3171d2798eeeefd744fb9 Mon Sep 17 00:00:00 2001 From: YuSanka Date: Wed, 14 Jun 2023 10:39:28 +0200 Subject: [PATCH] Follow up e28a913e - Added update of visibility for "flag" button --- src/slic3r/GUI/Tab.cpp | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/src/slic3r/GUI/Tab.cpp b/src/slic3r/GUI/Tab.cpp index e4c27abf8..ad93afa87 100644 --- a/src/slic3r/GUI/Tab.cpp +++ b/src/slic3r/GUI/Tab.cpp @@ -465,13 +465,19 @@ void Tab::OnActivate() if (m_presets_choice->IsShown()) Refresh(); // Just refresh page, if m_presets_choice is already shown else { - // on first OnActivate call show top sizer + // From the tab creation whole top sizer is hidden to correct update of preset combobox's size + // (see https://github.com/prusa3d/PrusaSlicer/issues/10746) + + // On first OnActivate call show top sizer m_top_hsizer->ShowItems(true); - // update visibility of action buttons + // Size and layouts of all items are correct now, + // but ALL items of top sizer are visible. + // So, update visibility of each item according to the ui settings update_btns_enabling(); - // update visibility of active extruder + m_btn_hide_incompatible_presets->Show(m_show_btn_incompatible_presets && m_type != Slic3r::Preset::TYPE_PRINTER); if (TabFilament* tab = dynamic_cast(this)) tab->update_extruder_combobox(); + Layout(); } }