Fixed conflicts after merge with master
This commit is contained in:
commit
48e90be2bc
1
deps/wxWidgets/wxWidgets.cmake
vendored
1
deps/wxWidgets/wxWidgets.cmake
vendored
@ -38,6 +38,7 @@ prusaslicer_add_cmake_project(wxWidgets
|
|||||||
-DwxUSE_LIBSDL=OFF
|
-DwxUSE_LIBSDL=OFF
|
||||||
-DwxUSE_XTEST=OFF
|
-DwxUSE_XTEST=OFF
|
||||||
-DwxUSE_GLCANVAS_EGL=OFF
|
-DwxUSE_GLCANVAS_EGL=OFF
|
||||||
|
-DwxUSE_WEBREQUEST=OFF
|
||||||
)
|
)
|
||||||
|
|
||||||
if (MSVC)
|
if (MSVC)
|
||||||
|
@ -988,6 +988,11 @@ Print::ApplyStatus Print::apply(const Model &model, DynamicPrintConfig new_full_
|
|||||||
DynamicPrintConfig filament_overrides;
|
DynamicPrintConfig filament_overrides;
|
||||||
t_config_option_keys print_diff = print_config_diffs(m_config, new_full_config, filament_overrides);
|
t_config_option_keys print_diff = print_config_diffs(m_config, new_full_config, filament_overrides);
|
||||||
t_config_option_keys full_config_diff = full_print_config_diffs(m_full_print_config, new_full_config);
|
t_config_option_keys full_config_diff = full_print_config_diffs(m_full_print_config, new_full_config);
|
||||||
|
// If just a physical printer was changed, but printer preset is the same, then there is no need to apply whole print
|
||||||
|
// see https://github.com/prusa3d/PrusaSlicer/issues/8800
|
||||||
|
if (full_config_diff.size() == 1 && full_config_diff[0] == "physical_printer_settings_id")
|
||||||
|
full_config_diff.clear();
|
||||||
|
|
||||||
// Collect changes to object and region configs.
|
// Collect changes to object and region configs.
|
||||||
t_config_option_keys object_diff = m_default_object_config.diff(new_full_config);
|
t_config_option_keys object_diff = m_default_object_config.diff(new_full_config);
|
||||||
t_config_option_keys region_diff = m_default_region_config.diff(new_full_config);
|
t_config_option_keys region_diff = m_default_region_config.diff(new_full_config);
|
||||||
|
@ -2438,8 +2438,10 @@ void GLCanvas3D::reload_scene(bool refresh_immediately, bool force_full_scene_re
|
|||||||
// refresh volume raycasters for picking
|
// refresh volume raycasters for picking
|
||||||
m_scene_raycaster.remove_raycasters(SceneRaycaster::EType::Volume);
|
m_scene_raycaster.remove_raycasters(SceneRaycaster::EType::Volume);
|
||||||
for (size_t i = 0; i < m_volumes.volumes.size(); ++i) {
|
for (size_t i = 0; i < m_volumes.volumes.size(); ++i) {
|
||||||
assert(m_volumes.volumes[i]->mesh_raycaster != nullptr);
|
const GLVolume* v = m_volumes.volumes[i];
|
||||||
add_raycaster_for_picking(SceneRaycaster::EType::Volume, i, *m_volumes.volumes[i]->mesh_raycaster, m_volumes.volumes[i]->world_matrix());
|
assert(v->mesh_raycaster != nullptr);
|
||||||
|
std::shared_ptr<SceneRaycasterItem> raycaster = add_raycaster_for_picking(SceneRaycaster::EType::Volume, i, *v->mesh_raycaster, v->world_matrix());
|
||||||
|
raycaster->set_active(v->is_active);
|
||||||
}
|
}
|
||||||
|
|
||||||
// refresh gizmo elements raycasters for picking
|
// refresh gizmo elements raycasters for picking
|
||||||
|
@ -527,10 +527,9 @@ bool PresetComboBox::selection_is_changed_according_to_physical_printers()
|
|||||||
return false;
|
return false;
|
||||||
|
|
||||||
const bool is_changed = selected_string == physical_printers.get_selected_printer_preset_name();
|
const bool is_changed = selected_string == physical_printers.get_selected_printer_preset_name();
|
||||||
|
physical_printers.unselect_printer();
|
||||||
if (is_changed)
|
if (is_changed)
|
||||||
tab->select_preset(selected_string);
|
tab->select_preset(selected_string);
|
||||||
physical_printers.unselect_printer();
|
|
||||||
|
|
||||||
return is_changed;
|
return is_changed;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -547,16 +546,18 @@ bool PresetComboBox::selection_is_changed_according_to_physical_printers()
|
|||||||
|
|
||||||
// if new preset wasn't selected, there is no need to call update preset selection
|
// if new preset wasn't selected, there is no need to call update preset selection
|
||||||
if (old_printer_preset == preset_name) {
|
if (old_printer_preset == preset_name) {
|
||||||
|
tab->update_preset_choice();
|
||||||
|
wxGetApp().plater()->show_action_buttons(false);
|
||||||
|
|
||||||
// we need just to update according Plater<->Tab PresetComboBox
|
// we need just to update according Plater<->Tab PresetComboBox
|
||||||
if (dynamic_cast<PlaterPresetComboBox*>(this)!=nullptr) {
|
if (dynamic_cast<PlaterPresetComboBox*>(this)!=nullptr) {
|
||||||
wxGetApp().get_tab(m_type)->update_preset_choice();
|
|
||||||
// Synchronize config.ini with the current selections.
|
// Synchronize config.ini with the current selections.
|
||||||
m_preset_bundle->export_selections(*wxGetApp().app_config);
|
m_preset_bundle->export_selections(*wxGetApp().app_config);
|
||||||
|
this->update();
|
||||||
}
|
}
|
||||||
else if (dynamic_cast<TabPresetComboBox*>(this)!=nullptr)
|
else if (dynamic_cast<TabPresetComboBox*>(this)!=nullptr)
|
||||||
wxGetApp().sidebar().update_presets(m_type);
|
wxGetApp().sidebar().update_presets(m_type);
|
||||||
|
|
||||||
this->update();
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -215,26 +215,30 @@ void Tab::create_preset_tab()
|
|||||||
sizer->Add(m_hsizer, 0, wxEXPAND | wxBOTTOM, 3);
|
sizer->Add(m_hsizer, 0, wxEXPAND | wxBOTTOM, 3);
|
||||||
m_hsizer->Add(m_presets_choice, 0, wxLEFT | wxRIGHT | wxTOP | wxALIGN_CENTER_VERTICAL, 3);
|
m_hsizer->Add(m_presets_choice, 0, wxLEFT | wxRIGHT | wxTOP | wxALIGN_CENTER_VERTICAL, 3);
|
||||||
m_hsizer->AddSpacer(int(4*scale_factor));
|
m_hsizer->AddSpacer(int(4*scale_factor));
|
||||||
m_hsizer->Add(m_btn_save_preset, 0, wxALIGN_CENTER_VERTICAL);
|
|
||||||
m_hsizer->AddSpacer(int(4*scale_factor));
|
m_h_buttons_sizer = new wxBoxSizer(wxHORIZONTAL);
|
||||||
m_hsizer->Add(m_btn_rename_preset, 0, wxALIGN_CENTER_VERTICAL);
|
m_h_buttons_sizer->Add(m_btn_save_preset, 0, wxALIGN_CENTER_VERTICAL);
|
||||||
m_hsizer->AddSpacer(int(4 * scale_factor));
|
m_h_buttons_sizer->AddSpacer(int(4*scale_factor));
|
||||||
m_hsizer->Add(m_btn_delete_preset, 0, wxALIGN_CENTER_VERTICAL);
|
m_h_buttons_sizer->Add(m_btn_rename_preset, 0, wxALIGN_CENTER_VERTICAL);
|
||||||
|
m_h_buttons_sizer->AddSpacer(int(4 * scale_factor));
|
||||||
|
m_h_buttons_sizer->Add(m_btn_delete_preset, 0, wxALIGN_CENTER_VERTICAL);
|
||||||
if (m_btn_edit_ph_printer) {
|
if (m_btn_edit_ph_printer) {
|
||||||
m_hsizer->AddSpacer(int(4 * scale_factor));
|
m_h_buttons_sizer->AddSpacer(int(4 * scale_factor));
|
||||||
m_hsizer->Add(m_btn_edit_ph_printer, 0, wxALIGN_CENTER_VERTICAL);
|
m_h_buttons_sizer->Add(m_btn_edit_ph_printer, 0, wxALIGN_CENTER_VERTICAL);
|
||||||
}
|
}
|
||||||
m_hsizer->AddSpacer(int(/*16*/8 * scale_factor));
|
m_h_buttons_sizer->AddSpacer(int(/*16*/8 * scale_factor));
|
||||||
m_hsizer->Add(m_btn_hide_incompatible_presets, 0, wxALIGN_CENTER_VERTICAL);
|
m_h_buttons_sizer->Add(m_btn_hide_incompatible_presets, 0, wxALIGN_CENTER_VERTICAL);
|
||||||
m_hsizer->AddSpacer(int(8 * scale_factor));
|
m_h_buttons_sizer->AddSpacer(int(8 * scale_factor));
|
||||||
m_hsizer->Add(m_question_btn, 0, wxALIGN_CENTER_VERTICAL);
|
m_h_buttons_sizer->Add(m_question_btn, 0, wxALIGN_CENTER_VERTICAL);
|
||||||
m_hsizer->AddSpacer(int(32 * scale_factor));
|
m_h_buttons_sizer->AddSpacer(int(32 * scale_factor));
|
||||||
m_hsizer->Add(m_undo_to_sys_btn, 0, wxALIGN_CENTER_VERTICAL);
|
m_h_buttons_sizer->Add(m_undo_to_sys_btn, 0, wxALIGN_CENTER_VERTICAL);
|
||||||
m_hsizer->Add(m_undo_btn, 0, wxALIGN_CENTER_VERTICAL);
|
m_h_buttons_sizer->Add(m_undo_btn, 0, wxALIGN_CENTER_VERTICAL);
|
||||||
m_hsizer->AddSpacer(int(32 * scale_factor));
|
m_h_buttons_sizer->AddSpacer(int(32 * scale_factor));
|
||||||
m_hsizer->Add(m_search_btn, 0, wxALIGN_CENTER_VERTICAL);
|
m_h_buttons_sizer->Add(m_search_btn, 0, wxALIGN_CENTER_VERTICAL);
|
||||||
m_hsizer->AddSpacer(int(8*scale_factor));
|
m_h_buttons_sizer->AddSpacer(int(8*scale_factor));
|
||||||
m_hsizer->Add(m_btn_compare_preset, 0, wxALIGN_CENTER_VERTICAL);
|
m_h_buttons_sizer->Add(m_btn_compare_preset, 0, wxALIGN_CENTER_VERTICAL);
|
||||||
|
|
||||||
|
m_hsizer->Add(m_h_buttons_sizer, 1, wxEXPAND);
|
||||||
m_hsizer->AddSpacer(int(16*scale_factor));
|
m_hsizer->AddSpacer(int(16*scale_factor));
|
||||||
// m_hsizer->AddStretchSpacer(32);
|
// m_hsizer->AddStretchSpacer(32);
|
||||||
// StretchSpacer has a strange behavior under OSX, so
|
// StretchSpacer has a strange behavior under OSX, so
|
||||||
@ -3192,6 +3196,7 @@ void Tab::update_btns_enabling()
|
|||||||
if (m_btn_edit_ph_printer)
|
if (m_btn_edit_ph_printer)
|
||||||
m_btn_edit_ph_printer->SetToolTip( m_preset_bundle->physical_printers.has_selection() ?
|
m_btn_edit_ph_printer->SetToolTip( m_preset_bundle->physical_printers.has_selection() ?
|
||||||
_L("Edit physical printer") : _L("Add physical printer"));
|
_L("Edit physical printer") : _L("Add physical printer"));
|
||||||
|
m_h_buttons_sizer->Layout();
|
||||||
}
|
}
|
||||||
|
|
||||||
void Tab::update_preset_choice()
|
void Tab::update_preset_choice()
|
||||||
|
@ -173,6 +173,7 @@ protected:
|
|||||||
ScalableButton* m_btn_edit_ph_printer {nullptr};
|
ScalableButton* m_btn_edit_ph_printer {nullptr};
|
||||||
ScalableButton* m_btn_hide_incompatible_presets;
|
ScalableButton* m_btn_hide_incompatible_presets;
|
||||||
wxBoxSizer* m_hsizer;
|
wxBoxSizer* m_hsizer;
|
||||||
|
wxBoxSizer* m_h_buttons_sizer;
|
||||||
wxBoxSizer* m_left_sizer;
|
wxBoxSizer* m_left_sizer;
|
||||||
wxTreeCtrl* m_treectrl;
|
wxTreeCtrl* m_treectrl;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user