mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-17 00:26:14 +03:00
Compare commits
6 Commits
82cedc0316
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b3fe733bf2 | ||
|
|
a0e1aa2507 | ||
|
|
95b23cea0f | ||
|
|
f760f4e462 | ||
|
|
9ec2fe3c45 | ||
|
|
a0717853df |
@@ -46,3 +46,12 @@ ctest --test-dir ./tests/fff_print
|
||||
- **Cross-platform** — all changes must work on Windows, macOS, and Linux
|
||||
- Profile/format changes need version migration handling
|
||||
- Dependencies built separately in `deps/build/`, then linked to main app
|
||||
|
||||
## Code review focus areas
|
||||
|
||||
- Changes must not cause regressions in existing functionality, defaults, profiles, or project compatibility.
|
||||
- Features gated by options must not affect existing behavior when those options are disabled.
|
||||
- Changes should follow the existing code style and architecture. Architectural changes should be justified in code comments and the PR description.
|
||||
- Add helper functions or utilities only when existing code cannot reasonably be reused. Avoid duplication.
|
||||
- Keep code concise and clear. Manually simplify AI generated bloated codes before review.
|
||||
- Include targeted tests or documented verification for behavior changes, especially in slicing logic, profiles, formats, and GUI defaults.
|
||||
|
||||
@@ -330,6 +330,8 @@ public:
|
||||
|
||||
size_t hash() const throw() override { return std::hash<T>{}(this->value); }
|
||||
|
||||
// Warning mitigation: Indicate that virtual serialize() is not forgotten
|
||||
using ConfigOption::serialize;
|
||||
private:
|
||||
friend class cereal::access;
|
||||
template<class Archive> void serialize(Archive & ar) { ar(this->value); }
|
||||
@@ -752,6 +754,8 @@ public:
|
||||
return modified;
|
||||
}
|
||||
|
||||
// Warning mitigation: Indicate that virtual serialize() is not forgotten
|
||||
using ConfigOptionVectorBase::serialize;
|
||||
private:
|
||||
friend class cereal::access;
|
||||
template<class Archive> void serialize(Archive & ar) { ar(this->values); }
|
||||
|
||||
@@ -2383,7 +2383,7 @@ void Sidebar::init_filament_combo(PlaterPresetComboBox **combo, const int filame
|
||||
|
||||
(*combo)->clr_picker->SetLabel(wxString::Format("%d", filament_idx + 1));
|
||||
combo_and_btn_sizer->Add((*combo)->clr_picker, 0, wxALIGN_CENTER_VERTICAL | wxRIGHT, FromDIP(SidebarProps::ElementSpacing()) - FromDIP(2)); // ElementSpacing - 2 (from combo box))
|
||||
combo_and_btn_sizer->Add(*combo, 1, wxALL | wxEXPAND, FromDIP(2))->SetMinSize({-1, FromDIP(30)});
|
||||
combo_and_btn_sizer->Add(*combo, 1, wxALL | wxEXPAND, FromDIP(2))->SetMinSize({-1, 30 * wxGetApp().em_unit() / 10}); // ORCA ensure height matches with PlaterPresetComboBox
|
||||
|
||||
/* BBS hide del_btn
|
||||
ScalableButton* del_btn = new ScalableButton(p->m_panel_filament_content, wxID_ANY, "delete_filament");
|
||||
|
||||
@@ -1009,6 +1009,32 @@ void UnsavedChangesDialog::build(Preset::Type type, PresetCollection *dependent_
|
||||
// "Save" button
|
||||
if (ActionButtons::SAVE & m_buttons) add_btn(&m_save_btn, m_save_btn_id, "save", Action::Save, _L("Save"), false);
|
||||
|
||||
if (dependent_presets != nullptr) {
|
||||
const wxString previous_profile = from_u8(dependent_presets->get_edited_preset().name);
|
||||
const wxString new_profile = new_selected_preset.empty() ? _L("the new profile") : from_u8(new_selected_preset);
|
||||
|
||||
if (m_discard_btn) {
|
||||
m_discard_btn->SetToolTip(format_wxstr(
|
||||
_L("Switch to\n\"%1%\"\ndiscarding any changes made in\n\"%2%\"."),
|
||||
new_profile,
|
||||
previous_profile));
|
||||
}
|
||||
|
||||
if (m_transfer_btn) {
|
||||
m_transfer_btn->SetToolTip(format_wxstr(
|
||||
_L("All \"New Value\" settings modified in\n\"%1%\"\nwill be transferred to\n\"%2%\"."),
|
||||
previous_profile,
|
||||
new_profile));
|
||||
}
|
||||
|
||||
if (m_save_btn) {
|
||||
m_save_btn->SetToolTip(format_wxstr(
|
||||
_L("All \"New Value\" settings are saved in\n\"%1%\"\nand \"%2%\" will open without any changes."),
|
||||
previous_profile,
|
||||
new_profile));
|
||||
}
|
||||
}
|
||||
|
||||
/* ScalableButton *cancel_btn = new ScalableButton(this, wxID_CANCEL, "cross", _L("Cancel"), wxDefaultSize, wxDefaultPosition, wxBORDER_DEFAULT, true, 24);
|
||||
buttons->Add(cancel_btn, 1, wxLEFT | wxRIGHT, 5);
|
||||
cancel_btn->SetFont(btn_font);*/
|
||||
|
||||
@@ -1518,6 +1518,7 @@ FlowRateCalibrationDialog::FlowRateCalibrationDialog(wxWindow* parent, wxWindowI
|
||||
|
||||
Layout();
|
||||
Fit();
|
||||
v_sizer->SetSizeHints(this);
|
||||
}
|
||||
|
||||
FlowRateCalibrationDialog::~FlowRateCalibrationDialog() {
|
||||
@@ -1540,7 +1541,6 @@ void FlowRateCalibrationDialog::on_start(wxCommandEvent& event) {
|
||||
|
||||
void FlowRateCalibrationDialog::on_dpi_changed(const wxRect& suggested_rect) {
|
||||
this->Refresh();
|
||||
Fit();
|
||||
}
|
||||
|
||||
}} // namespace Slic3r::GUI
|
||||
|
||||
Reference in New Issue
Block a user